Files
swift-mirror/test/SILGen/objc_imported_init.swift
Slava Pestov 91b980b94d SILGen: Dynamic, curry, foreign thunks should be serializable
This fixes a crash when referencing partially-applied methods
from @_inlineable functions.

Also, curry thunks for private methods do not need shared
linkage; private is sufficient.
2017-03-29 21:35:25 -07:00

14 lines
407 B
Swift

// RUN: %target-swift-frontend -verify -emit-silgen -sdk %S/Inputs -I %S/Inputs -enable-source-import %s | %FileCheck %s
// REQUIRES: objc_interop
import Foundation
// Ensure we emit allocating constructor thunks for ObjC initializers that
// were inherited.
// CHECK-LABEL: sil shared [serializable] @_T0So3FooCABycfC : $@convention(method) (@thick Foo.Type) -> @owned Foo {
func foo() {
_ = Foo()
}