|
[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] XML 1.0 spec appears to violate itself
I have been worndering whether the XML 1.0 specification represented in XML format is well-formed or not in the exact sense which the specification itself is supposed to define. For everyone's convenience, the file is located at the following URL. http://www.w3.org/TR/1998/REC-xml-19980210.xml On line 21, you can find the entity "lt" being redeclared as "<" as follows. <!ENTITY lt "<"> I remember there were some debate on this list discussing if such redeclaration is allowed in terms of the XML 1.0 specification. I am not trying to revive that thread in this message. Even if we assume "lt" could be redeclared in the internal DTD subset for now (I guess we can even extrapolate this is the case since the spec itself redeclares it), I believe it'll end up being violating well-formedness constraint for entities. In 4.3.2 "Well-Formed Parsed Entities" of the XML 1.0 spec, it states that: "An internal general parsed entity is well-formed if its replacement text matches the production labeled content. All internal parameter entities are well-formed by definition. A consequence of well-formedness in entities is that the logical and physical structures in an XML document are properly nested; no start-tag, end-tag, empty-element tag, element, comment, processing instruction, character reference, or entity reference can begin in one entity and end in another." And content is defined as: "content ::= (element | CharData | Reference | CDSect | PI | Comment)* " I think that XML processor shall find the entity as "not well-formed" when it tries to expand references to "lt" (i.e. < ) if it have been redeclared as "<", because "<" does not match the production rule for content. Am I missing something? = Takuki Kamiya Phone: (045)476-4586 Fax: (045)476-4749 = = FUJITSU LIMITED (COINS:7128-4217 NIFTY:HHA01731) = xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev@i... Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/ and on CD-ROM/ISBN 981-02-3594-1 To (un)subscribe, mailto:majordomo@i... the following message; (un)subscribe xml-dev To subscribe to the digests, mailto:majordomo@i... the following message; subscribe xml-dev-digest List coordinator, Henry Rzepa (mailto:rzepa@i...)
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|
|||||||||

Cart








