- From: C. M. Sperberg-McQueen <cmsmcq@blackmesatech.com>
- Date: Tue, 28 Nov 2023 09:51:44 -0700
- To: public-ixml@w3.org
It was observed on this morning's CG call that allowing names like
foo.
causes some difficulties for recursive-descent parsers (and any other
parser with limited lookahead, perhaps), which are out of all proportion
to the advantages, if any.
This is to propose a simple fix: continue to allow . to occur in names,
but forbid it to appear at the end of a name. Since no one on the call
remembered ever seeing an XML name with a final full stop outside of a
test suite, this did not seem likely to be a painful restriction.
Concretely, delete the current definitions:
@name: namestart, namefollower*.
-namestart: ["_"; L].
-namefollower: namestart; ["-.·‿⁀"; Nd; Mn].
and replace them with:
@name: namestart, namefollower*, ('.', namefollower*)*.
-namestart: ["_"; L].
-namefollower: namestart; ["-·‿⁀"; Nd; Mn].
or alternatively:
@name: namestart, (namefollower ** '.').
-namestart: ["_"; L].
-namefollower: namestart; ["-·‿⁀"; Nd; Mn].
Comments and discussion welcome. (And it occurs to me that someone
should check to make sure that this does actually address the LL(1)
issue.)
Michael
--
C. M. Sperberg-McQueen
Black Mesa Technologies LLC
http://blackmesatech.com
Received on Tuesday, 28 November 2023 17:03:42 UTC