RE: FW: XQuery: A.1.2 Lexical Rules

I don't mean to be overly negative, but has the W3C ever published a totally
correct grammar for anything?

In XPath 1.0, the grammar accidentally prohibited predicates on the
abbreviated paths . and .. (so .[pred] is syntactically invalid, even though
self::node()[pred] works fine).  I brought this error (and others) up with
most W3C members of that committee, and most of them refused even to admit
they had a mistake (even though it's been "fixed" in XPath 2.0).  Good
grief.

I've followed every XQuery internal and public draft since the first "XML
Query Algebra" paper (and implemented many of them), and the grammar of
*every* one of them has contained numerous errors and design flaws (many of
which I've provided feedback on through the Microsoft reps or this list).

I think the less the W3C attempts in the area of grammar specification, the
better.  For example, my personal implementation of the XQuery grammar uses
only five lexical states, and the complete source code for my lexer occupies
less space on paper than the current lexical description in the W3C draft.
You might as well publish an actual program instead of pages of useless
tables.

At least things have improved somewhat from the earlier drafts, at least one
of which contained an EBNF and two non-normative grammar files (for use with
compiler-generator tools like JavaCC), all three of which differed from one
another.


[And don't even get me started on stylistic issues, like the design and
purpose of character escapes in most languages vs. the W3C ones, or how the
grammars are unnecessarily way more permissive than the semantics.]


Cheers,

Michael Brundage
xquery@attbi.com

-----Original Message-----
From: public-qt-comments-request@w3.org
[mailto:public-qt-comments-request@w3.org] On Behalf Of
scott_boag@us.ibm.com
Sent: Friday, January 10, 2003 10:38 AM
To: Michael Dyck
Cc: public-qt-comments@w3.org
Subject: Re: FW: XQuery: A.1.2 Lexical Rules

>     (1) The PDA has appeared 4 times, each time with mistakes, sometimes
>         blatant, sometimes subtle. How confident are you that the final
>         version will be bug-free?

It's a long story, but a lot of the errors occurred as a result of our
document production process.  I'm currently working to make the production
of the lex tables much more straight-forward, so I'm reasonably confident we
can make this bug-free.

Received on Saturday, 11 January 2003 12:15:40 UTC