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

<!DOCTYPE foo> not invalid?

From: Mike Brown <mbrown@corp.webb.net>
Date: Wed, 23 Feb 2000 17:25:13 -0700
Message-ID: <8D96EDA0AC04D31197B400A0C96C14806A5CD3@ossex1.ossinc.net>
To: "'xml-editor@w3.org'" <xml-editor@w3.org>
I realize that it makes no sense to have neither an external subset
reference nor a literal internal subset in a document type declaration, but
my interpretation of Section 2.8 of the XML 1.0 Recommendation indicates
that a simple <!DOCTYPE foo> document type declaration would not be invalid
(unless the root element wasn't of type 'foo'). Tim Bray's annotated spec
doesn't address this situation, either.

1. Should such a declaration be invalid?
2. If it is not invalid, is there a recommended interpretation of such a
3. If this situation should have been addressed by the spec and wasn't, is
it worthy of a mention in the XML 1.0 Specification Errata document?

I haven't done extensive testing, but I am observing that the IBM XML4J
2.0.15 NonValidatingDOMParser class will not parse a document with such a
declaration, while the ValidatingSAXParser class doesn't seem to mind. I'd
like to know which behavior is correct before I report it as a bug.


   - Mike
Mike J. Brown, software engineer, Webb Interactive Services
XML/XSL stuff: http://www.skew.org/    http://www.webb.net/
Received on Wednesday, 23 February 2000 19:25:05 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:37:39 UTC