|Top Previous Next|
Examples > Java > Negative look ahead
In the production ArrayInitializer a WHILE loop is called:
WHILE( commaAndNoRBrace() )
commaAndNoRBrace ::= "," ( "}" EXIT )?
This means, the loop is executed as long, as a comma is following but no closing curly bracket follows the comma. If no comma follows, then commaAndNoRBrace cannot parse the current text. If a comma is following and a closing curly bracket '}' follows the comma, the look-ahead production commaAndNoRBrace also returns false. In this case this is forced by EXIT.
This page belongs to the TextTransformer Documentation
|Home Content German|