Esempio n. 1
0
        public virtual T VisitChildren(ASTVisitableElement node)
        {
            ASTVisitableElement oldParent = currentParent;

            currentParent = node;
            T result = default(T);

            foreach (ASTVisitableElement child in node.GetChildren())
            {
                result = AggregateResult(result, child.Accept(visitor: this));
            }
            currentParent = oldParent;
            return(result);
        }
Esempio n. 2
0
 public virtual T Visit(ASTVisitableElement node)
 {
     return(node.Accept(visitor: this));
 }