OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   Errata E57

[ Lists Home | Date Index | Thread Index ]

The new third edition of XML inspired me to read through the latest 
errata. I have a problem with one of them that I think is a 
substantial and unnecessary change to the definition of XML.

E57 states:

Amend the first paragraph after the example declarations so that it reads:

         The value "default" signals that applications' default 
white-space processing modes are acceptable for this element; the 
value "preserve" indicates the intent that applications preserve all 
the white space. This declared intent is considered to apply to all 
elements within the content of the element where it is specified, 
unless [E13]overridden with another instance of the xml:space 
attribute. This specification does not give meaning to any value of 
xml:space other than "default" and "preserve". It is an error for 
other values to be specified; the XML processor MAY report the error 
or MAY recover by ignoring the attribute specification or by 
reporting the (erroneous) value to the application. Applications may 
ignore or reject erroneous values.

Rationale
     Although the required behavior was clear when validating, it was 
under-specified when not validating. Making it an "error" makes it 
clear that "default" and "preserve" are the only blessed values, but 
that processors and applications are not obligated to react 
drastically.

I disagree with allowing nonvalidating processors to signal any form 
of error when encountering xml:space="something else". I think the 
previous spec was quite clear that this was not allowed, and that 
should not be changed now. Furthermore, in practice, these "maybe 
fatal, maybe not" errors are a huge pain in the posterior. They are a 
major source of interoperability problems between parsers. They were 
a mistake in the first place, and I really, really don't want to see 
any new ones blessed in the spec.

With regard to validating processors, the original spec is less 
clear. It states:

A special attribute named xml:space may be attached to an element to 
signal an intention that in that element, white space should be 
preserved by applications. In valid documents, this attribute, like 
any other, must be declared if it is used. When declared, it must be 
given as an enumerated type whose values are one or both of "default" 
and "preserve". For example:

A lot depends on the interpretation of "must" in the last sentence. 
In particular, is it a general rule for all declarations are does it 
just apply "In valid documents" as in the previous sentence. I prefer 
the latter interpretation, which would make it a validity error 
rather than a fatal error. Either way though, provided the attribute 
is properly declared in the DTD as specified here, I think it is 
still well-formed (though not valid) to have xml:space="something 
else" in a document parsed by a validating parser. I don't think this 
should be changed now.

One final meta-note: I really wish these errata would be publicly 
discussed and debated before being snuck out the door in the dead of 
night.
-- 

   Elliotte Rusty Harold
   elharo@metalab.unc.edu
   Effective XML (Addison-Wesley, 2003)
   http://www.cafeconleche.org/books/effectivexml
   http://www.amazon.com/exec/obidos/ISBN%3D0321150406/ref%3Dnosim/cafeaulaitA




 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS