[llvm] 8a4b6cd - [IR] Remove an unnecessary cast (NFC) (#146250)
via llvm-commits
llvm-commits at lists.llvm.org
Sat Jun 28 20:41:28 PDT 2025
Author: Kazu Hirata
Date: 2025-06-28T20:41:24-07:00
New Revision: 8a4b6cd8d80dbff55601e3291a71e0053793c108
URL: https://github.com/llvm/llvm-project/commit/8a4b6cd8d80dbff55601e3291a71e0053793c108
DIFF: https://github.com/llvm/llvm-project/commit/8a4b6cd8d80dbff55601e3291a71e0053793c108.diff
LOG: [IR] Remove an unnecessary cast (NFC) (#146250)
Agg is already of Type *.
Added:
Modified:
llvm/lib/IR/Instructions.cpp
Removed:
################################################################################
diff --git a/llvm/lib/IR/Instructions.cpp b/llvm/lib/IR/Instructions.cpp
index 8d9b545d4134f..3cfee89a1fdf5 100644
--- a/llvm/lib/IR/Instructions.cpp
+++ b/llvm/lib/IR/Instructions.cpp
@@ -2582,7 +2582,7 @@ Type *ExtractValueInst::getIndexedType(Type *Agg,
return nullptr;
}
}
- return const_cast<Type*>(Agg);
+ return Agg;
}
//===----------------------------------------------------------------------===//
More information about the llvm-commits
mailing list