I rebased incorrectly; there's a missing * in the const_cast type that gets 
fixed in r172446. Hopefully no one will pull this exact revision anyway.


On Jan 14, 2013, at 10:58 , Jordan Rose <[email protected]> wrote:

> Author: jrose
> Date: Mon Jan 14 12:58:38 2013
> New Revision: 172445
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=172445&view=rev
> Log:
> [analyzer] Fix cast-away-const warning by using const_cast.
> 
> Patch by David Greene, modified by me.
> 
> Modified:
>    
> cfe/trunk/include/clang/StaticAnalyzer/Core/PathSensitive/ProgramStateTrait.h
> 
> Modified: 
> cfe/trunk/include/clang/StaticAnalyzer/Core/PathSensitive/ProgramStateTrait.h
> URL: 
> http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/StaticAnalyzer/Core/PathSensitive/ProgramStateTrait.h?rev=172445&r1=172444&r2=172445&view=diff
> ==============================================================================
> --- 
> cfe/trunk/include/clang/StaticAnalyzer/Core/PathSensitive/ProgramStateTrait.h 
> (original)
> +++ 
> cfe/trunk/include/clang/StaticAnalyzer/Core/PathSensitive/ProgramStateTrait.h 
> Mon Jan 14 12:58:38 2013
> @@ -167,7 +167,7 @@
>     }
> 
>     static inline void *MakeVoidPtr(data_type D) {
> -      return  (void*) D.getInternalPointer();
> +      return const_cast<llvm::ImmutableListImpl<T> >(D.getInternalPointer());
>     }
> 
>     static inline context_type MakeContext(void *p) {
> 
> 
> _______________________________________________
> cfe-commits mailing list
> [email protected]
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to