diff --git a/lib/IR/Use.cpp b/lib/IR/Use.cpp index 481cbab7c29..1d343e80309 100644 --- a/lib/IR/Use.cpp +++ b/lib/IR/Use.cpp @@ -139,7 +139,7 @@ User *Use::getUser() const { const UserRef *ref = reinterpret_cast(End); return ref->getInt() ? ref->getPointer() - : (User*)End; + : reinterpret_cast(const_cast(End)); } } // End llvm namespace