[antlr-interest] Parse Tree (lack of) functionality

Aaron Armstrong ae.armstrong at gmail.com
Wed Mar 19 15:41:17 PDT 2008


I am using org.antlr.runtime.tree.ParseTree.  It defines various functions;
the ones of interest are:
getTokenStartIndex()
getTokenStopIndex()
setTokenStartIndex()
setTokenStopIndex()

Looking at ParseTree.class (using Eclipse), I see:
// Method descriptor #20 ()I
// Stack: 1, Locals: 1
public int getTokenStartIndex();
 0 iconst_0
 1 ireturn
   Line numbers:
    [pc: 0, line: 56]

//Method descriptor #25 (I)V
//Stack: 0, Locals: 2
public void setTokenStartIndex(int arg0);
 0 return
  Line numbers:
   [pc 0, line: 60]

//Method descriptor #20 ()I
//Stack: 1, Locals: 1
public int getTokenStopIndex();
 0 iconst_0
 1 ireturn
   Line numbers:
     [pc: 0, line: 63]

//Method descriptor #25 (I)V
//Stack: 1, Locals: 1
public void setTokenStopIndex(int arg0);
 0 return
  Line numbers:
   [pc: 0, line: 67]

I wanted to show the bytecode just to see that it isn't outdated.  However,
judging by what I see, these functions do literally nothing.

Just wanted to bring this up.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.antlr.org/pipermail/antlr-interest/attachments/20080319/cba0bb74/attachment.html 


More information about the antlr-interest mailing list