[llvm] a7044ed - [Attributor] Fix qualifier warning of the unittest
Luofan Chen via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 27 07:29:35 PDT 2020
Author: Luofan Chen
Date: 2020-07-27T22:28:39+08:00
New Revision: a7044edde71be0a4c70e79c503c39ce6bdd930e5
URL: https://github.com/llvm/llvm-project/commit/a7044edde71be0a4c70e79c503c39ce6bdd930e5
DIFF: https://github.com/llvm/llvm-project/commit/a7044edde71be0a4c70e79c503c39ce6bdd930e5.diff
LOG: [Attributor] Fix qualifier warning of the unittest
Reviewed By: jdoerfert
Differential Revision: https://reviews.llvm.org/D84532
Added:
Modified:
llvm/unittests/Transforms/IPO/AttributorTest.cpp
Removed:
################################################################################
diff --git a/llvm/unittests/Transforms/IPO/AttributorTest.cpp b/llvm/unittests/Transforms/IPO/AttributorTest.cpp
index 8c1682c01f30..7d496ed0d14f 100644
--- a/llvm/unittests/Transforms/IPO/AttributorTest.cpp
+++ b/llvm/unittests/Transforms/IPO/AttributorTest.cpp
@@ -44,8 +44,8 @@ TEST_F(AttributorTestBase, TestCast) {
Function *F = M.getFunction("foo");
- AbstractAttribute *AA = (AbstractAttribute *)&(
- A.getOrCreateAAFor<AAIsDead>(IRPosition::function(*F)));
+ const AbstractAttribute *AA =
+ &A.getOrCreateAAFor<AAIsDead>(IRPosition::function(*F));
EXPECT_TRUE(AA);
More information about the llvm-commits
mailing list