[antlr-interest] on parsers look and feel + #["="]
Ric Klaren
klaren at cs.utwente.nl
Mon Dec 1 05:18:39 PST 2003
Hi,
On Fri, Nov 28, 2003 at 05:57:39PM +0200, Cristian Amitroaie wrote:
> We still have an issue, that is #[] constructs when building ASTs. It's not
> straightforward. You need to write #[EQ, "="]. Why not #["="]? Afterall
> antlr computes a token table with enum_type/string/numbers associations...
>
> Maybe we should ask Terr for an enhancement?
Doing this in the tree construction stuff is probably not a good idea.
There's no unique mapping from AST type (e.g. as returned by getType()
(first parameter of #[x,y]) and the text (as returned by getText(), 2nd
parameter). So this can easily blow up. (As Thomas Brandon already pointed
out if I recall right)
Another reason against it is the crummy action parser interface in antlr
I'd rather not see this added on top of that (at least I won't touch it
with a 100ft pole after that happens unless its completely rewritten :)
that piece of code is enough of a horror already :(
Cheers,
Ric
--
-----+++++*****************************************************+++++++++-------
---- Ric Klaren ----- j.klaren at utwente.nl ----- +31 53 4893722 ----
-----+++++*****************************************************+++++++++-------
"I think we better split up."
"Good idea. We can do more damage that way."
--- Ghostbusters
Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
More information about the antlr-interest
mailing list