File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -493,7 +493,7 @@ struct ImmutableAddressUseVerifier {
493
493
return false ;
494
494
}
495
495
496
- bool isCastToNonConsuming (UncheckedAddrCastInst *i) {
496
+ bool isAddrCastToNonConsuming (SingleValueInstruction *i) {
497
497
// Check if any of our uses are consuming. If none of them are consuming, we
498
498
// are good to go.
499
499
return llvm::none_of (i->getUses (), [&](Operand *use) -> bool {
@@ -588,8 +588,9 @@ struct ImmutableAddressUseVerifier {
588
588
break ;
589
589
case SILInstructionKind::DestroyAddrInst:
590
590
return true ;
591
+ case SILInstructionKind::UpcastInst:
591
592
case SILInstructionKind::UncheckedAddrCastInst: {
592
- if (isCastToNonConsuming (cast<UncheckedAddrCastInst >(inst))) {
593
+ if (isAddrCastToNonConsuming (cast<SingleValueInstruction >(inst))) {
593
594
break ;
594
595
}
595
596
return true ;
You can’t perform that action at this time.
0 commit comments