On Feb 14, 2010, at 11:52 PM, Gavin Lambert wrote:

> At 14:54 15/02/2010, Michael Bedward wrote:
>> So, in this example you can't refactor the grammar to LL(k) but
>> you can have a simple, readable grammar for this part of the
>> language if you work with a back-tracking parser.
> 
> Or you put in the appropriate look-ahead predicates yourself.
> 
> Basically all ANTLR's backtracking mode does is to insert 
> lookahead predicates in every path and switch off ambiguity 
> warnings.  Consequently, while it's often useful while 
> experimenting, or with ridiculously ambiguous languages, it's 
> usually better to keep backtracking off, refactor, and add 
> predicates as needed.

ANTLR puts them in, but only uses them when necessary :)

Ter

List: http://www.antlr.org/mailman/listinfo/antlr-interest
Unsubscribe: 
http://www.antlr.org/mailman/options/antlr-interest/your-email-address

-- 
You received this message because you are subscribed to the Google Groups 
"il-antlr-interest" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/il-antlr-interest?hl=en.

Reply via email to