private Expression ParseConditionalTest(Expression trueExpr) { string ifWhiteSpace = _tokenWhiteSpace; Expression expr = ParseOrTest(); bool ateElse = Eat(TokenKind.KeywordElse); string elseWhiteSpace; Expression falseExpr; if (ateElse) { elseWhiteSpace = _tokenWhiteSpace; falseExpr = ParseExpression(); } else { elseWhiteSpace = null; falseExpr = Error(""); } var res = new ConditionalExpression(expr, trueExpr, falseExpr); if (_verbatim) { AddPreceedingWhiteSpace(res, ifWhiteSpace); AddSecondPreceedingWhiteSpace(res, elseWhiteSpace); if (!ateElse) { AddErrorIsIncompleteNode(res); } } return res; }
public override void PostWalk(ConditionalExpression node) { PostWalkWorker(node); }
public override bool Walk(ConditionalExpression node) { return UpdateLineInfo(node, true); }
// ConditionalExpression public override bool Walk(ConditionalExpression node) { return ShouldWalkWorker(node); }