[antlr-interest] Use of multimap in grammar file.
Alfredo Perez J.
xentastic at gmail.com
Wed Jan 26 09:40:53 PST 2011
Nevermind that previous post (accidentally doubled btw). My mind after many
hours couldn't see an extra ; that was there which caused the error.
Now I have a different quesiton if you mind.
I have some expression like this:
TRANSITION IDENTIFIER TO IDENTIFIER transFlags
Now what I want in this step is store IDENTIFIER.text from the left side and
IDENTIFIER.text from the right side, but how can I tell one from the other?
Tried something like this:
TRANSITION IDENTIFIER {Auxiliar = {$IDENTIFIER.text}} TO IDENTIFIER
transFlags
Auxiliar beign a String but I get the error: IDENTIFIER is a non-unique
reference.
I can't define some sort of "LeftIdentifier" because it's the same rule and
it won't be matched.
Any idea how can I differenciate these Identifiers?
More information about the antlr-interest
mailing list