W3C home > Mailing lists > Public > www-xml-schema-comments@w3.org > January to March 2004

Re: unbound prefixes and validity with xs:QName

From: Henry S. Thompson <ht@inf.ed.ac.uk>
Date: Sat, 21 Feb 2004 11:14:07 +0000
To: holstege@mathling.com
Cc: www-xml-schema-comments@w3.org
Message-ID: <f5bn07cadmo.fsf@erasmus.inf.ed.ac.uk>

One more reference to add to this discussion, which partially
contradicts one of Mary's incidental statements:

> Further, even if it did obtain, the difficulty with a QName with an
> unbound prefix isn't that there isn't a value, it is only that you
> don't _know_ what it is. So I would look at this as very much
> analogous to undischarged component references, where it isn't that
> you know something is wrong, it is that you don't know what the
> state of affairs is. And indeed, if the instance document were a
> schema, and the "qname" attribute above were instead a "type"
> attribute, this would be an entirely consistent view to take.

3.15.3 Constraints on XML Representations of Schemas [1] contains two
constraints which govern the use of QNames in schema documents, and in
instance documents when used in validation (i.e. xsi:type values).
The first of these does _explicitly require_ the prefix of QNames
which refer to components to be bound.  So a schema containing

 <xs:element name="foo" type="unbound:baz"/>

is _always_ an invalid schema, whether the element declaration is ever
'needed' or not.


[1] http://www.w3.org/XML/Group/2003/09/xmlschema-1/structures-with-errata.html#d0e16819
 Henry S. Thompson, HCRC Language Technology Group, University of
 Edinburgh Half-time member of W3C Team 2 Buccleuch Place, Edinburgh
 EH8 9LW, SCOTLAND -- (44) 131 650-4440 Fax: (44) 131 650-4587,
 e-mail: ht@inf.ed.ac.uk URL: http://www.ltg.ed.ac.uk/~ht/ [mail
 really from me _always_ has this .sig -- mail without it is forged
Received on Saturday, 21 February 2004 06:14:16 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 23:09:01 UTC