public override TResult Accept <TResult>(IParseTreeVisitor <TResult> visitor) { IQtVisitor <TResult> typedVisitor = visitor as IQtVisitor <TResult>; if (typedVisitor != null) { return(typedVisitor.VisitDefId(this)); } else { return(visitor.VisitChildren(this)); } }
/// <summary> /// Traverses all the nodes in the tree, calling 'branch' for branch nodes and 'leaf' for leaf nodes. /// </summary> /// <param name="visitor"></param> public abstract void Traverse(IQtVisitor visitor);