mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
12 lines
180 B
Swift
12 lines
180 B
Swift
// RUN: not %target-swift-frontend -typecheck %s
|
|
|
|
protocol P {
|
|
associatedtype A
|
|
}
|
|
|
|
func foo<T: P>(_: () throws -> T) -> T.A? {
|
|
fatalError()
|
|
}
|
|
|
|
_ = foo() { fatalError() } & nil
|