April 2002 Draft
JavaScript 2.0
Formal Description
Lexical Grammar
|
Monday, November 26, 2001
This LALR(1) grammar describes the lexical syntax of the JavaScript 2.0 proposal. See also the description of the grammar notation.
This document is also available as a Word 98 rtf file.
The start symbols are:
NextInputElementunit if the
previous input element was a number;
NextInputElementre if the
previous input element was not a number and a /
should be interpreted as a regular expression; and
NextInputElementdiv if the
previous input element was not a number and a /
should be interpreted as a division or division-assignment
operator.
«TAB»
| «VT»
| «FF»
| «SP»
| «u00A0»
«u2000»
| «u2001»
| «u2002»
| «u2003»
| «u2004»
| «u2005»
| «u2006»
| «u2007»
«u2008»
| «u2009»
| «u200A»
| «u200B»
«u3000»
_
}] IdentifierName!
!
=
!
=
=
%
%
=
&
&
&
&
&
=
&
=
(
)
*
*
=
+
+
+
+
=
,
-
-
-
-
=
.
.
.
.
:
:
:
;
<
<
<
<
<
=
<
=
=
=
=
=
=
=
>
>
=
>
>
>
>
=
>
>
>
>
>
>
=
?
[
]
^
^
=
^
^
^
^
=
{
|
|
=
|
|
|
|
=
}
~
.
Fraction
Waldemar Horwat Last modified Monday, November 26, 2001 |