We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9070974 commit b854ab1Copy full SHA for b854ab1
SwiftCompilerSources/Sources/Optimizer/Utilities/OwnershipLiveness.swift
@@ -365,6 +365,12 @@ extension OwnershipUseVisitor {
365
if let beginBorrow = BeginBorrowValue(resultOf: borrowInst) {
366
return visitInnerScopeUses(of: beginBorrow.value)
367
}
368
+ if let dependent = borrowInst.dependentValue {
369
+ if dependent.ownership == .guaranteed {
370
+ return visitAllUses(of: dependent)
371
+ }
372
+ return pointerEscapingUse(of: operand)
373
374
// Otherwise, directly visit the scope ending uses as leaf uses.
375
//
376
// TODO: remove this stack by changing visitScopeEndingOperands to take a non-escaping closure.
0 commit comments