[llvm] [ARM] Remove an unnecessary cast (NFC) (PR #155206)
Kazu Hirata via llvm-commits
llvm-commits at lists.llvm.org
Sun Aug 24 21:29:35 PDT 2025
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/155206
getType() already returns Type *.
>From 708589579aa0b3f0c73b9bd89f1b374ef50d423a Mon Sep 17 00:00:00 2001
From: Kazu Hirata <kazu at google.com>
Date: Sun, 24 Aug 2025 17:53:35 -0700
Subject: [PATCH] [ARM] Remove an unnecessary cast (NFC)
getType() already returns Type *.
---
llvm/lib/Target/ARM/ARMISelLowering.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/llvm/lib/Target/ARM/ARMISelLowering.cpp b/llvm/lib/Target/ARM/ARMISelLowering.cpp
index 12d2d678ff63a..40f636c49bf3d 100644
--- a/llvm/lib/Target/ARM/ARMISelLowering.cpp
+++ b/llvm/lib/Target/ARM/ARMISelLowering.cpp
@@ -3403,7 +3403,7 @@ SDValue ARMTargetLowering::LowerConstantPool(SDValue Op,
// position-independent addressing modes.
if (Subtarget->genExecuteOnly()) {
auto AFI = DAG.getMachineFunction().getInfo<ARMFunctionInfo>();
- auto T = const_cast<Type*>(CP->getType());
+ auto *T = CP->getType();
auto C = const_cast<Constant*>(CP->getConstVal());
auto M = DAG.getMachineFunction().getFunction().getParent();
auto GV = new GlobalVariable(
More information about the llvm-commits
mailing list