Re: [xml-dev] XML's Scylla and Charybdis - parse and regexp

From
Miles Sabin <>
To
Date
2003-04-01T16:40:16Z
ID
<>
Thread
Re: [xml-dev] XML's Scylla and Charybdis - parse and regexp
Jonathan Robie wrote,
> Is faithful lexical round-tripping an important goal? If so, why?

It's important to any application which is sensitive to the lexical 
characteristics of XML documents. They exist. If they're not yours then 
you don't have to care.

> If the Information Set says that there is no distinction between <foo
> "a"/> and <foo 'a'/>, why should I work hard to preserve the
> distinction?

If all you care about is the Infoset then you don't. But the XML REC 
does differentiate between the two at the lexical level, and some 
applications care about that.

That said, the API I mentioned predated both SAX2's LexicalHandler (and 
the Infoset REC), and the primary motivation was preserving comments 
rather than quotemarks ... in particular I wanted to be able to 
round-trip without dropping comments with, eg., embedded copyright 
information.

Cheers,


Miles