[PATCH] D92932: RegionInfo: use a range-based for loop [NFCI]
Nicolai Hähnle via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Dec 9 04:30:22 PST 2020
nhaehnle created this revision.
nhaehnle requested review of this revision.
Herald added a project: LLVM.
Change-Id: I9985d72191a2b0680195032acf8a14ad2ba954ed
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D92932
Files:
llvm/include/llvm/Analysis/RegionInfoImpl.h
Index: llvm/include/llvm/Analysis/RegionInfoImpl.h
===================================================================
--- llvm/include/llvm/Analysis/RegionInfoImpl.h
+++ llvm/include/llvm/Analysis/RegionInfoImpl.h
@@ -585,10 +585,8 @@
// Exit is the header of a loop that contains the entry. In this case,
// the dominance frontier must only contain the exit.
if (!DT->dominates(entry, exit)) {
- for (typename DST::iterator SI = entrySuccs->begin(),
- SE = entrySuccs->end();
- SI != SE; ++SI) {
- if (*SI != exit && *SI != entry)
+ for (BlockT *successor : *entrySuccs) {
+ if (successor != exit && successor != entry)
return false;
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D92932.310499.patch
Type: text/x-patch
Size: 718 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20201209/483ef648/attachment.bin>
More information about the llvm-commits
mailing list