diff options
author | Kazu Hirata <kazu@google.com> | 2021-11-14 09:32:38 -0800 |
---|---|---|
committer | Kazu Hirata <kazu@google.com> | 2021-11-14 09:32:38 -0800 |
commit | 7379736774475e80a58023b95afa8a7cca5f7007 (patch) | |
tree | 136ce2e8e319e9a0a24f7c434fb58c2fa0534481 /llvm/lib/CodeGen/MachineFunction.cpp | |
parent | 098e935174933dcb3871afb0d51d16cb8acc2401 (diff) | |
download | llvm-7379736774475e80a58023b95afa8a7cca5f7007.zip llvm-7379736774475e80a58023b95afa8a7cca5f7007.tar.gz llvm-7379736774475e80a58023b95afa8a7cca5f7007.tar.bz2 |
[llvm] Use range-based for loops with User::operands (NFC)
Diffstat (limited to 'llvm/lib/CodeGen/MachineFunction.cpp')
-rw-r--r-- | llvm/lib/CodeGen/MachineFunction.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/llvm/lib/CodeGen/MachineFunction.cpp b/llvm/lib/CodeGen/MachineFunction.cpp index d8f786e..366d068 100644 --- a/llvm/lib/CodeGen/MachineFunction.cpp +++ b/llvm/lib/CodeGen/MachineFunction.cpp @@ -746,9 +746,8 @@ MCSymbol *MachineFunction::addLandingPad(MachineBasicBlock *LandingPad) { // Add filters in a list. auto *CVal = cast<Constant>(Val); SmallVector<const GlobalValue *, 4> FilterList; - for (User::op_iterator II = CVal->op_begin(), IE = CVal->op_end(); - II != IE; ++II) - FilterList.push_back(cast<GlobalValue>((*II)->stripPointerCasts())); + for (const Use &U : CVal->operands()) + FilterList.push_back(cast<GlobalValue>(U->stripPointerCasts())); addFilterTypeInfo(LandingPad, FilterList); } |