[antlr-interest] Re: multilexer - almost, but no cigar. (One more thing...)

Craig Main craig at palantir.co.za
Thu Feb 6 00:11:01 PST 2003


Hi Micheal, (and others)

Please could you give me some help?
I am closer, but still not quite there.

This is almost working. I have stuffed up the CODE_BEGIN and CODE_END again
somehow.

At least it is recognising the "if" and "foreach" separately now, but it's
moaning about the '[' characters.

The output looks like this,
----------------------------------------------------------
this is a test
int i = 0;
line 3:2: expecting CODE_END, found 'if'

procedure pop;
line 5:2: expecting CODE_END, found 'foreach'

end
test
test
newitem
line 10:3: expecting CODE_END, found 'if'

new
line 12:2: expecting CODE_END, found 'foreach'

end
----------------------------------------------------------



 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/ 

-------------- next part --------------
Common
CODE_BEGIN=4
CODE_END=5
-------------- next part --------------
A non-text attachment was scrubbed...
Name: code.g
Type: application/octet-stream
Size: 867 bytes
Desc: not available
Url : http://www.antlr.org/pipermail/antlr-interest/attachments/20030206/e4b45d6b/code.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: xgen.g
Type: application/octet-stream
Size: 950 bytes
Desc: not available
Url : http://www.antlr.org/pipermail/antlr-interest/attachments/20030206/e4b45d6b/xgen.obj
-------------- next part --------------
this is a test
int i = 0;
[if]
procedure pop;
[foreach]
end
test
test
newitem
[ if ]
new
[foreach]
end
-------------- next part --------------
A non-text attachment was scrubbed...
Name: main.cpp
Type: application/octet-stream
Size: 1805 bytes
Desc: not available
Url : http://www.antlr.org/pipermail/antlr-interest/attachments/20030206/e4b45d6b/main.obj


More information about the antlr-interest mailing list