public virtual void PostWalk(IndexExpr node) { }
// IndexExpr public virtual bool Walk(IndexExpr node) { return true; }
public override void PostWalk(IndexExpr node) { }
// IndexExpr public override bool Walk(IndexExpr node) { return false; }
private Expr ParseIndexExpr(Expr target) { Eat(TokenType.LeftBracket); List<Expr> indexes = new List<Expr>(); do { indexes.Add(ParseExpr()); } while (MaybeEat(TokenType.Comma)); var ret = new IndexExpr(target, indexes.ToArray()); ret.SetLoc(_globalParent, ret.StartIndex, GetEnd()); Eat(TokenType.RightBracket); return ret; }
// IndexExpr public override bool Walk(IndexExpr node) { node.Parent = _currentScope; return base.Walk(node); }