[cfe-commits] r70317 - in /cfe/trunk: lib/AST/ExprConstant.cpp test/Sema/const-eval.c
Mike Stump
mrs at apple.com
Wed Apr 29 13:12:32 PDT 2009
On Apr 28, 2009, at 12:17 PM, Eli Friedman wrote:
> Author: efriedma
> Date: Tue Apr 28 14:17:36 2009
> New Revision: 70317
>
> URL: http://llvm.org/viewvc/llvm-project?rev=70317&view=rev
> Log:
> PR4097: add logic to Evaluate to handle pointer equality comparisons.
> + bool Result;
> + if (E->getOpcode() == BinaryOperator::EQ) {
> + Result = LHSValue.getLValueOffset() ==
> RHSValue.getLValueOffset();
> + } else if (E->getOpcode() == BinaryOperator::NE) {
> + Result = LHSValue.getLValueOffset() !=
> RHSValue.getLValueOffset();
> + }
> + return Success(Result, E);
?
ExprConstant.cpp: In member function
‘bool<unnamed>::IntExprEvaluator::VisitBinaryOperator(const
clang::BinaryOperator*)’:
ExprConstant.cpp:927: warning: ‘Result’ may be used uninitialized in
this function
More information about the cfe-commits
mailing list