XML News from Sunday, November 9, 2003

The W3C has posted the proposed recommendations of XML 1.1 and Namespaces in XML 1.1. These are bad ideas, for reasons I've elaborated before, both here and elsewhere. Allow me to quote myself:

Everything you need to know about XML 1.1 can be summed up in two rules:

  1. Don't use it.

  2. (For experts only) If you speak Mongolian, Yi, Cambodian, Amharic, Dhivehi, Burmese or a very few other languages and you want to write your markup (not your text but your markup) in these languages, then you can set the version attribute of the XML declaration to 1.1. Otherwise, refer to rule 1.

These drafts do not appear to introduce any substantive changes since the candidate recommendations. In particular a change that would have prohibited line breaks in the XML declaration appears to have been rescinded at the last minute, probably because that would have required the spec to go back to last call. Instead, it is not stated that "The characters #x85 and #x2028 cannot be reliably recognized and translated until an entity's encoding declaration (if present) has been read. Therefore, it is a fatal error to use them within the XML declaration or text declaration."

Update: I missed something on my first read through. There is a substantive change in the proposed recommendation of XML 1.1 (In direct violation of the W3C's advertised process, I'll note). C0 control characters such as BEL and vertical tab are now allowed directly in XML documents. They no longer have to be escaped with numeric character references. Among other effects, this makes it much harder to detect documents which whose encoding declaration is incorrect.

Update to the update: It appears this was an an unintentional failure in the editing. Several working group members have told me they meant to forbid literal control characters. They simply forgot to do it. Expect at least one more draft before the final recommendation. However, even if this problem is fixed, I still think XML 1.1 is a bad idea, and should not be recommended.

Comments on both drafts are due by December 5.