mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
SIL: Make drop_deinit a ForwardingInstruction.
drop_deinit forwards ownership while effectively stripping the deinitializer. It is similar to a type cast. Fixes rdar://125590074 ([NonescapableTypes] Nonescapable types cannot have deinits)
This commit is contained in:
@@ -1885,6 +1885,10 @@ bool MarkDependenceInst::visitNonEscapingLifetimeEnds(
|
||||
return !noUsers;
|
||||
}
|
||||
|
||||
bool DestroyValueInst::isFullDeinitialization() {
|
||||
return !isa<DropDeinitInst>(lookThroughOwnershipInsts(getOperand()));
|
||||
}
|
||||
|
||||
PartialApplyInst *
|
||||
DestroyValueInst::getNonescapingClosureAllocation() const {
|
||||
SILValue operand = getOperand();
|
||||
|
||||
Reference in New Issue
Block a user