antlr

Class ASTPair

public class ASTPair extends Object

ASTPair: utility class used for manipulating a pair of ASTs representing the current AST root and current AST sibling. This exists to compensate for the lack of pointers or 'var' arguments in Java.
Field Summary
ASTchild
ASTroot
Method Summary
voidadvanceChildToEnd()
Make sure that child is the last sibling
ASTPaircopy()
Copy an ASTPair.
StringtoString()

Field Detail

child

public AST child

root

public AST root

Method Detail

advanceChildToEnd

public final void advanceChildToEnd()
Make sure that child is the last sibling

copy

public ASTPair copy()
Copy an ASTPair. Don't call it clone() because we want type-safety

toString

public String toString()