blob: c4c062dc77b77bce1a11569070442f0cb7b2a963 [file] [log] [blame]
// RUN: %empty-directory(%t)
// RUN: %target-build-swift %S/Inputs/capture_propagation_linkage/main.swift %s -O -o %t/a.out
// RUN: %target-codesign %t/a.out
// RUN: %target-run %t/a.out | %FileCheck %s
// REQUIRES: executable_test
// CHECK: test ok
// Capture propagation specializes the reabstraction thunk for createInstance
// and for main.createNil().
//
// We used to have a problem which caused us to mark these as private
// since both would produce the same name. Now we no longer have this
// problem due to the new mangler.
func createSome() -> MyClass? {
return genericCaller(createInstance)
}
func createInstance() -> MyClass? {
return MyClass()
}