Ok, I fixed the problem, my "b" was out of scope in that class and I 
fixed it using a member.
But I still have a problem if the else-part is missing...


fridi schrieb:
> Hi,
>
> i have  a parser rule for an if-else
>
> rule
>   :
>   IF^ expression 'then'! actionSequence ('else'! actionSequence)? 'endif'!
>   ;
>
> The treewalker rule is
>
> ifElse
>   :
>   ^(
>     IF b=expression
>     (
>       {b}?=> actionSequence .
>       | . actionSequence
>     )
>    )
>   ;
>
> The problem now is that the generated code for DFA1 and there the method 
> specialStateTransition() does not know about my variable b
> Any ideas?
>
> Thanks in advance,
>  fridi
>
> 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.

Reply via email to