[antlr-interest] Strange hangup in the Parser

Terence Parr parrt at cs.usfca.edu
Thu Jun 16 10:11:47 PDT 2011


hi. it's a server waiting for socket connection from ANTLRWorks.
Ter
On Jun 16, 2011, at 8:38 AM, David Smith wrote:

> This seems to happen to me frequently, and I'm not sure what I change 
> to fix it, but it consumes a considerable amount of time - I think 
> the ultimate cure is rebooting my computer.
> 
> In the code generated by AtlrWorks, I find this:
> 
>         public ExprParser(TokenStream input, int port,
>                           RecognizerSharedState state) {
>             super(input, state);
>             DebugEventSocketProxy proxy =
>                 new DebugEventSocketProxy(this,port,adaptor);
>             setDebugListener(proxy);
>             setTokenStream(new DebugTokenStream(input,proxy));
>             try {
>                 proxy.handshake();  /****** hangs up here! **********/
>             }
>             catch (IOException ioe) {
>                 reportError(ioe);
>             }
>             TreeAdaptor adap = new CommonTreeAdaptor();
>             setTreeAdaptor(adap);
>             proxy.setTreeAdaptor(adap);
>         }
> When I try to run in debug mode, the thing just hangs up at the line:
>     proxy.handshake();
> 
> Any ideas?
> 
>                                 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