mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
13 lines
289 B
Swift
13 lines
289 B
Swift
// RUN: %target-swift-frontend -emit-sil -verify %s | %FileCheck %s
|
|
|
|
class A {}
|
|
class B: A {}
|
|
|
|
func test<T>(_ type: T.Type) -> T? {
|
|
fatalError()
|
|
}
|
|
|
|
// CHECK: [[RESULT:%.*]] = function_ref @$s12rdar628426514testyxSgxmlF
|
|
// CHECK-NEXT: apply [[RESULT]]<B>({{.*}})
|
|
let _: A? = test(B.self)
|