mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
15 lines
315 B
Swift
15 lines
315 B
Swift
// RUN: %target-swift-emit-silgen %s | %FileCheck %s
|
|
|
|
struct Foo<T> {}
|
|
struct Bar {}
|
|
|
|
extension Foo where T == Bar {
|
|
func foo(x: T) -> Bar {
|
|
// CHECK-LABEL: sil private [ossa] @{{.*}}3foo{{.*}}4foo2{{.*}} : $@convention(thin) (Bar) -> Bar
|
|
func foo2() -> Bar {
|
|
return x
|
|
}
|
|
return foo2()
|
|
}
|
|
}
|