NMTOKEN elements?

I was thinking about how XML schemas allow the specification of types for
both elements and attributes, and how the old attribute types are retained
for backward compatibility, and I realized that this allowed for the
possibility of NMTOKEN elements (not to mention NMTOKENS elements). 

The bottom of the first table in 2.3 of the schema primer
(http://www.w3.org/TR/xmlschema-0/#CreatDt) tells us that "to retain
compatibility between XML Schema and XML 1.0 DTDs, the simple types ID,
IDREF, IDREFS, ENTITY, ENTITIES, NOTATION, NMTOKEN, NMTOKENS should only be
used in attributes." The normative spec doesn't mention this; in fact, an
example there actually uses it: in section 4.3.3 of Part 1 of the spec, the
definition of a complexType called "length2" includes a subelement ("unit")
declared as being of type NMTOKEN.

Section 3.3.3 of the XML spec (http://www.w3.org/TR/REC-xml#AVNormalize)
describes specific responsibilities of an XML parser for, among other
things, normalizing the space included with a non-CDATA attribute value.
Without this normalization, there's not much point in using NMTOKEN. Have a
parser's responsibilities regarding NMTOKEN  element types been addressed
anywhere?

Bob DuCharme          www.snee.com/bob           <bob@  
snee.com>  "The elements be kind to thee, and make thy
spirits all of comfort!" Anthony and Cleopatra, III ii

Received on Friday, 23 June 2000 10:15:42 UTC