Posted By:
Anonymous
Posted On:
Saturday, April 27, 2002 10:33 AM
I have a problem when running ANTLR on my test-file. The file looks like this: runsequence( 0: spawn(groupA); 50: spawn(groupB); 200: startevent(eventA); 400: kill(groupA); startevent(eventA); 2000: terminate; ); Now when I compile I get the error: "unexpected token: terminate" But it should be there, what is the problem and how can I fix it? Here the ANTLR code: runsequence : RUNSEQUENCE_CALL SP round_seq EP ; round_seq : (round_events)* termination ; round_events : INTEGER SEPARATOR r_events (r_events)*
More>>
I have a problem when running ANTLR on my test-file. The file looks like this:
runsequence(
0: spawn(groupA);
50: spawn(groupB);
200: startevent(eventA);
400: kill(groupA); startevent(eventA);
2000: terminate;
);
Now when I compile I get the error: "unexpected token: terminate" But it should be there, what is the problem and how can I fix it?
Here the ANTLR code:
runsequence
: RUNSEQUENCE_CALL
SP
round_seq
EP
;
round_seq
: (round_events)*
termination
;
round_events
: INTEGER
SEPARATOR
r_events (r_events)*
;
r_events
: event_call
SP
VARIABLE
EP
EOE
;
event_call
: SPAWN_CALL
| KILL_CALL
| STARTEVENT_CALL
;
termination
: INTEGER
SEPARATOR
TERMINATION_CALL
EOE
;
<<Less