Fix getTrueExpr for ConditionalOperator to actually work. No testcase

because it's currently unused.

llvm-svn: 52166
This commit is contained in:
Eli Friedman 2008-06-10 05:00:13 +00:00
parent 8030749993
commit d48188e8e0
1 changed files with 1 additions and 1 deletions

View File

@ -972,7 +972,7 @@ public:
// e.g: x ?: y is shorthand for x ? x : y, except that the expression "x"
// is only evaluated once.
Expr *getTrueExpr() const {
return SubExprs[LHS] ? SubExprs[COND] : SubExprs[LHS];
return SubExprs[LHS] ? SubExprs[LHS] : SubExprs[COND];
}
// getTrueExpr - Return the subexpression representing the value of the ?: