[antlr-interest] BindException on DEFAULT_DEBUGGER_PORT resp. endless loop with another port

Gavin Lambert antlr at mirality.co.nz
Tue Mar 17 11:44:15 PDT 2009


At 06:09 18/03/2009, Matthias Kiehl wrote:
 >No Problem I thought, just change the port - I used 49100. For 
now
 >the BindException doesn't appear, but my app seems to run in an
 >endless loop.
 >
 >Running the same grammar with the interpreter of ANTLR IDE or 
with
 >interpreter or debugger in ANTLRWorks everything seems correct,
 >giving me the expected AST.
 >Also everything is OK when I use a small sample grammar within
 >Eclipse.

If you compiled your grammar with -debug, then it will wait on 
startup for a connection from ANTLRWorks before continuing.  When 
you're not using ANTLRWorks, you should regenerate your 
parser/lexer without -debug.

 >ORDERBY	:	O R D E R ' '+ B Y;

In this and similar rules, you might want to call the WS rule (or 
something like it) instead of coding the space 
directly.  Otherwise it won't match cases where the user has put 
tabs or newlines between the two halves of the keyword -- which 
would probably be unusual, but normally isn't illegal.



More information about the antlr-interest mailing list