diff options
author | Chris Lattner <sabre@nondot.org> | 2008-11-16 21:24:15 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2008-11-16 21:24:15 +0000 |
commit | 6ee7aa154e8bbb21a21254293410b944f78b0bfe (patch) | |
tree | 1c72e4ab41df953f8e3a89b34b162b3183ff12f8 /lib/Sema/SemaDecl.cpp | |
parent | 9ad16aebc0e840a5e7d425da72eb6cbe25e4b58c (diff) |
rename Expr::tryEvaluate to Expr::Evaluate.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@59426 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaDecl.cpp')
-rw-r--r-- | lib/Sema/SemaDecl.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/Sema/SemaDecl.cpp b/lib/Sema/SemaDecl.cpp index dd76e15c09..1ecaaa370a 100644 --- a/lib/Sema/SemaDecl.cpp +++ b/lib/Sema/SemaDecl.cpp @@ -1560,11 +1560,11 @@ bool Sema::CheckArithmeticConstantExpression(const Expr* Init) { // specified arm of the conditional to be a constant. This is a horrible // hack, but is require by real world code that uses __builtin_constant_p. APValue Val; - if (!Exp->getCond()->tryEvaluate(Val, Context)) { - // If the tryEvaluate couldn't fold it, CheckArithmeticConstantExpression + if (!Exp->getCond()->Evaluate(Val, Context)) { + // If Evaluate couldn't fold it, CheckArithmeticConstantExpression // won't be able to either. Use it to emit the diagnostic though. bool Res = CheckArithmeticConstantExpression(Exp->getCond()); - assert(Res && "tryEvaluate couldn't evaluate this constant?"); + assert(Res && "Evaluate couldn't evaluate this constant?"); return Res; } @@ -2494,7 +2494,7 @@ static QualType TryToFixInvalidVariablyModifiedType(QualType T, APValue Result; if (!VLATy->getSizeExpr() || - !VLATy->getSizeExpr()->tryEvaluate(Result, Context)) + !VLATy->getSizeExpr()->Evaluate(Result, Context)) return QualType(); assert(Result.isInt() && "Size expressions must be integers!"); |