mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
12 lines
311 B
Swift
12 lines
311 B
Swift
// RUN: %target-swift-frontend -emit-sil -swift-version 6 %s -o /dev/null -verify
|
|
|
|
class NonSendableKlass {}
|
|
|
|
protocol P {
|
|
subscript(_: sending NonSendableKlass) -> sending NonSendableKlass { get }
|
|
}
|
|
|
|
struct S: P {
|
|
subscript(_: sending NonSendableKlass) -> sending NonSendableKlass { NonSendableKlass() }
|
|
}
|