[cfe-commits] r172561 - /cfe/trunk/lib/StaticAnalyzer/Core/ExprEngine.cpp

David Greene greened at obbligato.org
Tue Jan 15 14:09:45 PST 2013


Author: greened
Date: Tue Jan 15 16:09:45 2013
New Revision: 172561

URL: http://llvm.org/viewvc/llvm-project?rev=172561&view=rev
Log:
Fix Cast

Properly use const_cast to fix a cast-away-const error.

Modified:
    cfe/trunk/lib/StaticAnalyzer/Core/ExprEngine.cpp

Modified: cfe/trunk/lib/StaticAnalyzer/Core/ExprEngine.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/StaticAnalyzer/Core/ExprEngine.cpp?rev=172561&r1=172560&r2=172561&view=diff
==============================================================================
--- cfe/trunk/lib/StaticAnalyzer/Core/ExprEngine.cpp (original)
+++ cfe/trunk/lib/StaticAnalyzer/Core/ExprEngine.cpp Tue Jan 15 16:09:45 2013
@@ -1043,7 +1043,8 @@
   // Add the special flag to GDM to signal retrying with no inlining.
   // Note, changing the state ensures that we are not going to cache out.
   ProgramStateRef NewNodeState = BeforeProcessingCall->getState();
-  NewNodeState = NewNodeState->set<ReplayWithoutInlining>((void*)CE);
+  NewNodeState =
+    NewNodeState->set<ReplayWithoutInlining>(const_cast<Stmt *>(CE));
 
   // Make the new node a successor of BeforeProcessingCall.
   bool IsNew = false;





More information about the cfe-commits mailing list