[antlr-interest] Adding java class in AntlrWorks debug mode

Terence Parr parrt at cs.usfca.edu
Thu Apr 28 10:55:00 PDT 2011


Hi David, I suggest that you use remote debugging. Just say debug remote instead of debug from the drop-down menu. When you start up your parser from the command line, it will go into server mode. AW then asked the client and attached to that server to suck out debug events.
Ter
On Apr 28, 2011, at 10:49 AM, David Smith wrote:

> I am working with a team of students at Georgia Tech to develop a 
> Java version of Matlab.  In particular, I want to integrate the 
> grammar with our production system so that we can debug the grammar, 
> generate the code and run our system without having to edit the lex 
> and parser class files.  This requires (I think) that we change the 
> actions in the grammar from something like:
> {  memory.put($ID.gettext, $expr.value);
>    System.out.println("store variable" + $ID.getText);
> }
> to something lie
> {
>    Interface.put($ID.gettext, $expr.value);
>    Interface.display("store variable" + $ID.getText);
> }
> This works fine if I generate code and compile our system with the 
> Antlr lex and parser classes and a version if the Interface class 
> that uses memory and System.out as above.
> However, I can't figure out how to include this Interface class with 
> the AntlrWorks debugger.
> Any help would be greatly appreciated.
> 
>                                 DMS
> 
> David M. Smith http://www.cc.gatech.edu/fac/David.Smith
> Georgia Institute of Technology, College of Computing
> Sent from my ASR-33 Teletype  
> 
> 
> List: http://www.antlr.org/mailman/listinfo/antlr-interest
> Unsubscribe: http://www.antlr.org/mailman/options/antlr-interest/your-email-address



More information about the antlr-interest mailing list