[llvm] 7246049 - [unittest] Fix -Wunused-variable after D94717
Fangrui Song via llvm-commits
llvm-commits at lists.llvm.org
Fri May 7 11:42:21 PDT 2021
Author: Fangrui Song
Date: 2021-05-07T11:42:16-07:00
New Revision: 724604901a104d8ba9e48ca0330e164a66c1c7ac
URL: https://github.com/llvm/llvm-project/commit/724604901a104d8ba9e48ca0330e164a66c1c7ac
DIFF: https://github.com/llvm/llvm-project/commit/724604901a104d8ba9e48ca0330e164a66c1c7ac.diff
LOG: [unittest] Fix -Wunused-variable after D94717
Added:
Modified:
llvm/unittests/Analysis/LoopInfoTest.cpp
Removed:
################################################################################
diff --git a/llvm/unittests/Analysis/LoopInfoTest.cpp b/llvm/unittests/Analysis/LoopInfoTest.cpp
index db6484f6928f..550458c27018 100644
--- a/llvm/unittests/Analysis/LoopInfoTest.cpp
+++ b/llvm/unittests/Analysis/LoopInfoTest.cpp
@@ -1534,8 +1534,7 @@ TEST(LoopInfoTest, LoopUserBranch) {
runWithLoopInfo(*M, "foo", [&](Function &F, LoopInfo &LI) {
Function::iterator FI = F.begin();
FI = ++FI;
- BasicBlock *Guard = &*FI;
- assert(Guard->getName() == "guard");
+ assert(FI->getName() == "guard");
FI = ++FI;
BasicBlock *Header = &*(++FI);
More information about the llvm-commits
mailing list