Next: Name Analysis
Up: Relating Phrase Structure to
Previous: Expressions
The concrete syntax for Java introduces a large number of nonterminals for
the purpose of removing the ``dangling else'' ambiguity, and also to
differentiate statements for the purposes of exposition.
In most of these cases no special semantics are associated with these
nonterminals, and therefore there is no need to distinguish them in the
tree:
Statements ::= StatementsOpt ConstructorStatements .
Statement ::=
StatementWithoutTrailingSubstatement StatementNoShortIf
IfThenStatement IfThenElseStatement IfThenElseStatementNoShortIf
BreakStatement ContinueStatement
EmptyStatement
ReturnStatement
SynchronizedStatement
ThrowStatement
TryStatement .
ExpressionStatement ::=
ExplicitConstructorInvocation .
LabeledStatement ::= LabeledStatementNoShortIf .
WhileStatement ::= WhileStatementNoShortIf .
ForStatement ::= ForStatementNoShortIf .
This macro is invoked in definition 22.
2008-09-11