diff options
-rw-r--r-- | lib/Transforms/Scalar/InstructionCombining.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Transforms/Scalar/InstructionCombining.cpp b/lib/Transforms/Scalar/InstructionCombining.cpp index 79d79011f4..1c4bceaef4 100644 --- a/lib/Transforms/Scalar/InstructionCombining.cpp +++ b/lib/Transforms/Scalar/InstructionCombining.cpp @@ -5683,7 +5683,7 @@ bool InstCombiner::transformConstExprCastCall(CallSite CS) { if (Callee->isExternal() && !(OldRetTy->isLosslesslyConvertibleTo(FT->getReturnType()) || (isa<PointerType>(FT->getReturnType()) && - OldRetTy->isLosslesslyConvertibleTo(TD->getIntPtrType()))) + TD->getIntPtrType()->isLosslesslyConvertibleTo(OldRetTy))) && !Caller->use_empty()) return false; // Cannot transform this return value... |