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

Re: [PATCH] Remove .svn/README.txt

From: Branko ─îibej <brane_at_xbc.nu>
Date: 2004-11-09 04:01:45 CET

C. Michael Pilato wrote:

>This is almost a no-brainer optimization, because we read the entries
>and format files in conjunction so often. My only (small) concern is
>that if the format number is inside the entries file, we have to start
>reading that file without knowing what format to expect the
>information to be in. If we happen to lose XML in our entries files
>altogether (or something like that), the format version change can't
>be noticed before firing up the wrong kind of parser.
>
>
Ah, but you can avoid this problem quite easily by blessing Philip's
experiment for real use. Use the first line in the file for the format
number, and pipe what's left to the appropriately selected parser.
Certainly this would cause an ordinary XML parser to barf on our entries
file, but I can't muster much sympathy for people who don't use the
libsvn_wc functions to fiddle with the entries file.

It's also fairly easy to detect the file format before piping to the
parser, even without that hack. If it starts with "<?xml", it's XML, and
we can require that the format number is an attribute of the wc-entries
element, which is the first thing the XML parser will read, so it can
adjust schema recognition accordingly. If we change the format, the file
won't start with "<?xml" and we can certainly make sure that any new
format is equally recognisable.

-- Brane

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Tue Nov 9 04:01:53 2004

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