From 2c4d52467a25aed5ec9ed868fe8b74a1a67d1535 Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Sun, 5 Jun 2022 00:16:14 -0700 Subject: [Transforms/Utils] Use predecessors (NFC) --- 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 a060975..42cdece 100644 --- a/llvm/lib/Transforms/Utils/Local.cpp +++ b/llvm/lib/Transforms/Utils/Local.cpp @@ -1126,7 +1126,7 @@ bool llvm::TryToSimplifyUncondBranchFromEmptyBlock(BasicBlock *BB, // If there is more than one pred of succ, and there are PHI nodes in // the successor, then we need to add incoming edges for the PHI nodes // - const PredBlockVector BBPreds(pred_begin(BB), pred_end(BB)); + const PredBlockVector BBPreds(predecessors(BB)); // Loop over all of the PHI nodes in the successor of BB. for (BasicBlock::iterator I = Succ->begin(); isa(I); ++I) { -- cgit v1.1