the interp has some flaws ;)
T
On Feb 15, 2010, at 5:40 AM, Fabien Antoine wrote:
> Hum...my question seems to be forgotten.
> I don't think that's a difficult thing but a simple explanation of this
> could be great!
>
> Fabien
>
> On 11/02/2010 13:36, Fabien Antoine wrote:
>> Hi list,
>>
>> I'm a new user of this great tool and I don't understand some things
>> with the interpreter...
>> I've the following grammar:
>>
>> grammar Test;
>> options {
>> backtrack = true;
>> memoize = true;
>> }
>>
>> testOK
>> : ID
>> | INT
>> ;
>>
>> testKO
>> : testID
>> | testINT
>> ;
>> testID
>> : ID
>> ;
>> testINT
>> : INT
>> ;
>>
>> ID : ('a'..'z'|'A'..'Z')+
>> ;
>> INT : ('0'..'9')+
>> ;
>>
>>
>> And then when I write the text "test" in the interpreter it works fine
>> with "testOK" and I get a FailedPredicateException exception with "testKO".
>> There are some explanations to this feature because for me it should be
>> the same thing?
>>
>> Thanks for your answers!!
>>
>> Fabien
>>
>
>
> List: http://www.antlr.org/mailman/listinfo/antlr-interest
> Unsubscribe:
> http://www.antlr.org/mailman/options/antlr-interest/your-email-address
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.