[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] Add -p to show C function names was Re: [PATCH] Extra options for libsvn_diff

From: David Glasser <glasser_at_davidglasser.net>
Date: 2007-12-26 22:51:27 CET

On Dec 26, 2007 1:47 PM, Justin Erenkrantz <justin@erenkrantz.com> wrote:
> On Dec 26, 2007 1:40 PM, David Glasser <glasser@davidglasser.net> wrote:
> > On Dec 26, 2007 11:30 AM, Justin Erenkrantz <justin@erenkrantz.com> wrote:
> > > I'd like to resurrect this discussion - IOW, I want Subversion to
> > > support -p out-of-the-box to print C-style function names.
> >
> > Agreed. I always use --diff-cmd diff -x -up for this reason (and wish
> > that the svn.collab.net commit mails did as well, though that's an
> > orthogonal issue).
> >
> > I think it would be reasonable to make svn's implementation compatible
> > with GNU diff's, though; the regexp it uses is /^[[:alpha:]$_]/,
> > whereas the patch is essentially /^[[:alpha:]0-9]/.
>
> Calling it a regex is being generous. The patch just calls:
>
> && svn_ctype_isalnum(*curp))
>
> Perhaps, we could improve it to:
>
> && (svn_ctype_isalpha(*curp) || *curp == '$' || *curp == '_')
>
> ?
>
> Or, am I mis-groking the suggested regexp? -- justin

Yup, that's what I'm suggesting.

(I'm calling it a regexp because that's how the GNU diff info page
documents -p; it documents it in terms of -F, which lets you specify a
regexp.)

--dave

-- 
David Glasser | glasser_at_davidglasser.net | http://www.davidglasser.net/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Dec 26 22:51:51 2007

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.