File tree Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -190,9 +190,8 @@ class PreservedAnalyses {
190
190
PreservedIDs.erase (ID);
191
191
NotPreservedAnalysisIDs.insert (ID);
192
192
}
193
- for (auto *ID : PreservedIDs)
194
- if (!Arg.PreservedIDs .count (ID))
195
- PreservedIDs.erase (ID);
193
+ PreservedIDs.remove_if (
194
+ [&](void *ID) { return !Arg.PreservedIDs .contains (ID); });
196
195
}
197
196
198
197
// / Intersect this set with a temporary other set in place.
@@ -212,9 +211,8 @@ class PreservedAnalyses {
212
211
PreservedIDs.erase (ID);
213
212
NotPreservedAnalysisIDs.insert (ID);
214
213
}
215
- for (auto *ID : PreservedIDs)
216
- if (!Arg.PreservedIDs .count (ID))
217
- PreservedIDs.erase (ID);
214
+ PreservedIDs.remove_if (
215
+ [&](void *ID) { return !Arg.PreservedIDs .contains (ID); });
218
216
}
219
217
220
218
// / A checker object that makes it easy to query for whether an analysis or
@@ -316,4 +314,4 @@ class PreservedAnalyses {
316
314
};
317
315
} // namespace llvm
318
316
319
- #endif
317
+ #endif
You can’t perform that action at this time.
0 commit comments