[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Accepting non-deterministic content models
- From: John Cowan <email@example.com>
- To: Lars Marius Garshol <firstname.lastname@example.org>
- Date: Sun, 08 Jul 2001 12:54:43 -0400 (EDT)
Lars Marius Garshol scripsit:
> The only reason to reject non-deterministic content models is because
> the SGML standard requires it, and so for backwards compatibility XML
> did the same. This is also why the requirement is so vague. It doesn't
> say "should", it says "for compatibility, it is an error if...".
Meaning that XML processors MAY handle such documents, but nobody can
rely on their doing so.
This was done so that existing SGML parsers could handle XML. I still
often parse XML with nsgmls, for example.
> If this approach is followed, you have to do extra work to detect
> whether the original content model was "non-deterministic". In fact,
> the reason why xmlproc accepts such content models (as Tom Passin
> reports) is that I haven't implemented this check yet. I don't think
> there's all that much point in doing so, either.
The language "it is an error" means that your processor need not
detect it. So if you don't want to add it, don't.
> Now that we've ended up with a spec that is the way it is, I think the
> best course to follow for an implementation is to accept such content
> models, but to warn about them.
That too is a reasonable course of action, since it protects
the document author against non-portable documents.
John Cowan email@example.com
One art/there is/no less/no more/All things/to do/with sparks/galore