mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
So call the destroy on the closing type instead. Amends the concepts areFieldsABIAccessible/isABIAccessible to take metadata accessibility of non-copyable types into account. rdar://133990500
25 lines
414 B
Swift
25 lines
414 B
Swift
fileprivate struct PrivateType : ~Copyable {
|
|
let x = 5
|
|
|
|
deinit {
|
|
print("deinit")
|
|
}
|
|
}
|
|
|
|
public struct PublicType : ~Copyable {
|
|
fileprivate let p = PrivateType()
|
|
|
|
public init() {}
|
|
}
|
|
|
|
public enum PublicSinglePayloadEnum : ~Copyable {
|
|
case empty
|
|
case some(PrivateType)
|
|
}
|
|
|
|
public enum PublicMultiPayloadEnum : ~Copyable {
|
|
case empty
|
|
case some(PrivateType)
|
|
case someOther(PrivateType)
|
|
}
|