HANDBOOK / GENTLE PRIMER / Describing Syntax /

# Rule Selection

The rule-selection strategy used for nonterm predicates differs from that of actions and conditions. Instead of backtracking, an LALR(1) parsing algorithm is used. The Gentle compiler passes the underlying grammar to the parser generator Yacc. When Yacc processes the grammar it may flag certain rules as violating restrictions of this method. (See the documentation on Yacc for details of how to deal with this.)

Rule selection depends exclusively on the structure of the input and is not controlled by failure of predicates.