W3C home > Mailing lists > Public > xml-editor@w3.org > April to June 1998

XML 1.0 query: "<?XML" vs "<?xml"

From: Kent M Pitman <kmp@harlequin.com>
Date: Fri, 17 Apr 98 04:20:33 EDT
Message-Id: <9804170820.AA01342@excel.harlequin.com>
To: xml-editor@w3.org
Cc: kmp@harlequin.com
In 2.6 Processing Instructions, syntax definition [17] 
defines

 PITarget ::= Name - (( 'X' | 'x' ) ( 'M' | 'm' ) ( 'L' | 'l' ))

but later in 2.8, syntax definition 23 defines

 XMLDecl ::= '<?xml' VersionInfo EncodingDecl? SDDecl? S? '?>'

Note that 'xml' is all lowercase here.  Does the match algorithm specify
that case doesn't matter in multiple-character strings?

Section 6 defines 'string' as matching a 'literal string',
so literally 'xml' would be case-sensitive, no?

The most reasonable fix would seem to be:

 [17]   PITarget ::= Name - XMLname
 [17.1] XMLname  ::= (( 'X' | 'x' ) ( 'M' | 'm' ) ( 'L' | 'l' ))
 [23]   XMLDecl ::= '<?' XMLname VersionInfo EncodingDecl? SDDecl? S? '?>'
 [77] ...etc.

Alternatively, if the XML declaration must be in lowercase (which, by the
way, is incompatible with your draft spec and surely an annoyance to any
actual users), then why do you reserve the uppercase space in PITarget?

By the way, XML is an uppercase acronym, and it troubles my personal
sense of aesthetics to see it required to be given in lowercase.
 -kmp


-----------
DISCLAIMER:
 The above are my personal feelings and not necessarily 
 Harlequin's official position.
Received on Friday, 17 April 1998 04:17:11 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 7 December 2009 10:59:29 GMT