@@ -805,10 +805,6 @@ struct OwnershipLifetimeExtender {
805805 // / the BorrowedValue that begins the scope.
806806 SILValue borrowOverSingleUse (SILValue newValue,
807807 Operand *singleGuaranteedUse);
808-
809- SILValue
810- borrowOverSingleNonLifetimeEndingUser (SILValue newValue,
811- SILInstruction *nonLifetimeEndingUser);
812808};
813809
814810} // end anonymous namespace
@@ -1092,27 +1088,6 @@ OwnershipLifetimeExtender::borrowOverSingleUse(SILValue newValue,
10921088 return newBeginBorrow;
10931089}
10941090
1095- SILValue OwnershipLifetimeExtender::borrowOverSingleNonLifetimeEndingUser (
1096- SILValue newValue, SILInstruction *nonLifetimeEndingUser) {
1097- // Avoid borrowing guaranteed function arguments.
1098- if (isa<SILFunctionArgument>(newValue) &&
1099- newValue->getOwnershipKind () == OwnershipKind::Guaranteed) {
1100- return newValue;
1101- }
1102- auto borrowPt = newValue->getNextInstruction ()->getIterator ();
1103- return borrowCopyOverGuaranteedUsers (
1104- newValue, borrowPt, ArrayRef<SILInstruction *>(nonLifetimeEndingUser));
1105- }
1106-
1107- SILValue swift::makeGuaranteedValueAvailable (SILValue value,
1108- SILInstruction *user,
1109- DeadEndBlocks &deBlocks,
1110- InstModCallbacks callbacks) {
1111- OwnershipFixupContext ctx{callbacks, deBlocks};
1112- OwnershipLifetimeExtender extender{ctx};
1113- return extender.borrowOverSingleNonLifetimeEndingUser (value, user);
1114- }
1115-
11161091// ===----------------------------------------------------------------------===//
11171092// OwnershipRAUWUtility - RAUW + fix ownership
11181093// ===----------------------------------------------------------------------===//
0 commit comments