Skip to content

Commit b7f5aac

Browse files
committed
[ownership] Delete dead code that explicitly handles interior pointers open_existental_box, store_borrow.
These both are already classified as interior pointers. Thus, we would have already handled them at the top of the loop where we handle interior pointer operands.
1 parent a223d37 commit b7f5aac

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

lib/SIL/Utils/OwnershipUtils.cpp

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -648,16 +648,15 @@ bool BorrowedValue::visitInteriorPointerOperandHelper(
648648
if (isa<DebugValueInst>(user) || isa<SuperMethodInst>(user) ||
649649
isa<ClassMethodInst>(user) || isa<CopyValueInst>(user) ||
650650
isa<EndBorrowInst>(user) || isa<ApplyInst>(user) ||
651-
isa<StoreBorrowInst>(user) || isa<StoreInst>(user) ||
652-
isa<PartialApplyInst>(user) || isa<UnmanagedRetainValueInst>(user) ||
651+
isa<StoreInst>(user) || isa<PartialApplyInst>(user) ||
652+
isa<UnmanagedRetainValueInst>(user) ||
653653
isa<UnmanagedReleaseValueInst>(user) ||
654654
isa<UnmanagedAutoreleaseValueInst>(user)) {
655655
continue;
656656
}
657657

658658
// These are interior pointers that have not had support yet added for them.
659-
if (isa<OpenExistentialBoxInst>(user) ||
660-
isa<ProjectExistentialBoxInst>(user)) {
659+
if (isa<ProjectExistentialBoxInst>(user)) {
661660
continue;
662661
}
663662

0 commit comments

Comments
 (0)