W3C home > Mailing lists > Public > xml-editor@w3.org > January to March 1998

Suspected Error in XML 1.0 Specification

From: <David_Wittler/ATL/Lotus@lotus.com>
Date: Wed, 25 Mar 1998 11:28:37 -0500
To: xml-editor@w3.org
Message-ID: <852565D2.0058DCA1.00@mta2.lotus.com>
In http://www.w3.org/TR/1998/REC-xml-19980210 "CharData" is defined as
follows:

[14]  CharData ::=  [^<&]* - ([^<&]* ']]>' [^<&]*)

As such it matches a string of 0 characters.  Shouldn't it be defined as:

[14]  CharData ::=  [^<&]+ - ([^<&]* ']]>' [^<&]*)

CharData is only used in the production:

[43]  content ::=  (element | CharData | Reference | CDSect | PI |
Comment)*

This already allows "content" to be empty.  If the XML processor were
parsing

<tag><\tag>

it could legally generate any number of emtpy CharData objects by the first
definition.
Received on Wednesday, 25 March 1998 11:33:45 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 7 December 2009 10:59:29 GMT