[antlr-interest] paraphrase without lexer

Ric Klaren klaren at cs.utwente.nl
Mon Apr 15 09:11:53 PDT 2002


On Mon, Apr 15, 2002 at 05:05:25PM +0200, Silvain Piree wrote:
> extending Antlr would probably be the best solution (and not that difficult
> to implement, although we'd have to agree on the syntax), but ... the
> process
> of getting changes into the Antlr codebase is very unclear to me, so I
> usually create workarounds outside Antlr.

Syntax would be the same as for lexer. Only problem is that some additional
checks might be necessary. Basically disabling the lexer only check for
paraphrase would work on tokens only (I think). It's a 3-5 line change in
RuleBlock.java.

Try it out and if it's as I think it might be a simple patch. Then feeding
it to me wouldn't be a big problem.

Basically changes to the codebase are done by ppl submitting patches to the
maintainers (Terence, me and a few others with repository write access)

> As such, I really like your solution of overriding reportError. Thank you
> for that suggestion!

No problem ;)

Cheers,

Ric
-- 
-----+++++*****************************************************+++++++++-------
    ---- Ric Klaren ----- klaren at cs.utwente.nl ----- +31 53 4893722  ----
-----+++++*****************************************************+++++++++-------
 Why don't we just invite them to dinner and massacre them all when they're
  drunk? You heard the man. There's seven hundred thousand of them. Ah? ..
           So it'd have to be something simple with pasta, then.
                 From: Interesting Times by Terry Pratchet


 

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



More information about the antlr-interest mailing list