RE: [xsl] xmlns created literally

Subject: RE: [xsl] xmlns created literally
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Date: Thu, 26 Feb 2009 16:21:41 -0000
> It's well formed xml, and namespace wellformed.

I'm not sure it is. Namespaces 1.1 is very ambiguous (and 1.0 is essentially
identical):

Section 3: "The attribute's normalized value MUST be either an IRI reference
- the namespace name identifying the namespace - or an empty string. "

Section 7 Conformance of Documents: "A document is namespace-well-formed if
it conforms to this specification." (!)

Section 8 Conformance of Processors: "a processor MUST report violations of
namespace well-formedness, with the exception that it is not REQUIRED to
check that namespace names are legal IRIs. "

There's nothing in Section 7 that explicitly links the definition of
namespace-well-formedness (or conformance) to the "MUST" in section 3. Some
think that "conforms to this specification" includes only compliance with
the rules in section 7 that explicitly discuss the requirements for
conformance, some people seem to think it includes all "MUST"s anywhere in
the spec. I asked for a more explicit statement during the comment period on
the spec, and the WG declined to add one, and as far as I can tell, the
reason is that they couldn't agree among themselves.

What is clear is that parsers aren't required to report it as an error, and
in practice most don't. XOM is notorious for rejecting invalid namespace
names, and it causes users a lot of grief.

Michael Kay
http://www.saxonica.com/

Current Thread