From 781aa181abddaa26c9f9bb06340f314d30095e50 Mon Sep 17 00:00:00 2001 From: Craig Topper Date: Sat, 5 May 2018 01:57:00 +0000 Subject: Fix a bunch of places where operator-> was used directly on the return from dyn_cast. Inspired by r331508, I did a grep and found these. Mostly just change from dyn_cast to cast. Some cases also showed a dyn_cast result being converted to bool, so those I changed to isa. llvm-svn: 331577 --- llvm/lib/Transforms/Utils/Local.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'llvm/lib/Transforms/Utils/Local.cpp') diff --git a/llvm/lib/Transforms/Utils/Local.cpp b/llvm/lib/Transforms/Utils/Local.cpp index 99fd2906754..d9601556595 100644 --- a/llvm/lib/Transforms/Utils/Local.cpp +++ b/llvm/lib/Transforms/Utils/Local.cpp @@ -2496,7 +2496,7 @@ bool llvm::canReplaceOperandWithVariable(const Instruction *I, unsigned OpIdx) { // Static allocas (constant size in the entry block) are handled by // prologue/epilogue insertion so they're free anyway. We definitely don't // want to make them non-constant. - return !dyn_cast(I)->isStaticAlloca(); + return !cast(I)->isStaticAlloca(); case Instruction::GetElementPtr: if (OpIdx == 0) return true; -- cgit v1.2.3