]> granicus.if.org Git - clang/commit
Added getTrueExpr() and getFalseExpr() to ConditionalOperator. These methods
authorTed Kremenek <kremenek@apple.com>
Mon, 3 Dec 2007 17:09:21 +0000 (17:09 +0000)
committerTed Kremenek <kremenek@apple.com>
Mon, 3 Dec 2007 17:09:21 +0000 (17:09 +0000)
commit395a2abf0028968d85958610e393e067885dc14f
tree15cf0c225c5387d58d0c6465b8bf203ddf52883f
parent43d69750e7f7b26076e7474dec8839bb777b260f
Added getTrueExpr() and getFalseExpr() to ConditionalOperator. These methods
provide handy accessors to the subexpressions of ConditionalOperator that
automatically take into account the GCC extension where the "LHS" expression is
omitted: e.g x ?: y;. When the LHS expression is available, getTrueExpr() is the
same as getLHS(); when LHS is NULL, getTrueExpr() returns the condition expression.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44536 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/AST/Expr.h