Files
swift-mirror/test/SILGen/c_materializeForSet_linkage.swift
Jordan Rose 25985cb764 [Mangling] Uniformly use "So" for imported decls.
...and repurpose "SC" for (C)lang-importer-synthesized decls, instead
of just decls that are C-like instead of ObjC-like. (See next commits.)
2017-04-24 09:57:30 -07:00

27 lines
893 B
Swift

// RUN: %target-swift-frontend -sdk %S/Inputs -I %S/Inputs -enable-source-import %s -emit-silgen | %FileCheck %s
// REQUIRES: objc_interop
import AppKit
protocol Pointable {
var x: Float { get set }
var y: Float { get set }
}
extension NSPoint: Pointable {}
extension NSReferencePoint: Pointable {}
// Make sure synthesized materializeForSet and its callbacks have shared linkage
// for properties imported from Clang
// CHECK-LABEL: sil shared [transparent] [serializable] @_T0So7NSPointV1xSffm
// CHECK-LABEL: sil shared [transparent] [serializable] @_T0So7NSPointV1ySffm
// CHECK-LABEL: sil shared [serializable] @_T0So16NSReferencePointC1xSffmytfU_
// CHECK-LABEL: sil shared [serializable] @_T0So16NSReferencePointC1xSffm
// CHECK-LABEL: sil shared [serializable] @_T0So16NSReferencePointC1ySffmytfU_
// CHECK-LABEL: sil shared [serializable] @_T0So16NSReferencePointC1ySffm