Example #1
0
		public virtual void PostWalk(ConditionalExpr node) { }
Example #2
0
		// ConditionalExpr
		public virtual bool Walk(ConditionalExpr node) { return true; }
Example #3
0
		public override void PostWalk(ConditionalExpr node) { }
Example #4
0
		// ConditionalExpr
		public override bool Walk(ConditionalExpr node) { return false; }
Example #5
0
        private Expr ParseConditionalExpr()
        {
            Expr ret = ParseLogicalOrExpr();
            if (ret == null)
                return ret;

            if (MaybeEat(TokenType.Questionmark))
            {
                Expr ifTrue = ParseExpr();
                Eat(TokenType.Colon);
                Expr ifFalse = ParseExpr();

                var start = ret.StartIndex;
                ret = new ConditionalExpr(ret, ifTrue, ifFalse);
                ret.SetLoc(_globalParent, start, GetEnd());
            }
            return ret;
        }
		// ConditionalExpr
		public override bool Walk(ConditionalExpr node)
		{
			node.Parent = _currentScope;
			
			return base.Walk(node);
		}