Does anybody know about ECMAScript for XML (E4X; ECMA-357 2º edition) and read its specification? Deprecated, I know. To start my question, please let me point somethings first:
E4X allows expressions like <x/>, thus extending PrimaryExpression with a XMLInitialiser | XMLListInitialiser production.
However, they say:
The syntactic grammar for XML initialisers processes input elements produced by the lexical grammar goal symbols InputElementXMLTag and InputElementXMLContent. These input elements are described in section 8.3.
(and same for XML list.)
So, isn't XMLInitialiser supposed to also process InputElementRegExp? The specification tries to reject that. Please check these definitions:
XMLInitialiser :
XMLMarkupXMLElement
XMLElement :
- <
XMLTagContentXMLWhitespaceopt />
and also,
InputElementXMLContent ::
- <
- and more...
They all make < available, but then how would one parse other expressions that need InputElementRegExp?
This just gave me an headache. But, re-looking up the section 8, there's an example where,
is equivalent to
(specification bitmap)
I believe the < production in the
InputElementXMLContentwas a mistake.