File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -279,9 +279,13 @@ bool PartialApplyCombiner::processSingleApply(FullApplySite paiAI) {
279
279
SILInstruction *PartialApplyCombiner::combine () {
280
280
// We need to model @unowned_inner_pointer better before we can do the
281
281
// peephole here.
282
- for (auto resultInfo : pai->getSubstCalleeType ()->getResults ())
283
- if (resultInfo.getConvention () == ResultConvention::UnownedInnerPointer)
284
- return nullptr ;
282
+ if (llvm::any_of (pai->getSubstCalleeType ()->getResults (),
283
+ [](SILResultInfo resultInfo) {
284
+ return resultInfo.getConvention () ==
285
+ ResultConvention::UnownedInnerPointer;
286
+ })) {
287
+ return nullptr ;
288
+ }
285
289
286
290
// Iterate over all uses of the partial_apply
287
291
// and look for applies that use it as a callee.
You can’t perform that action at this time.
0 commit comments