Files
swift-mirror/test/IRGen/objc_class_allocator.swift
Ellie Shin 72a7760027 Support package SIL linkage.
Decls with a package access level are currently set to public SIL
linkages. This limits the ability to have more fine-grained control
and optimize around resilience and serialization.
This PR introduces a separate SIL linkage and FormalLinkage for
package decls, pipes them down to IRGen, and updates linkage checks
at call sites to include package linkage.

Resolves rdar://121409846
2024-02-06 01:23:14 -08:00

16 lines
442 B
Swift

// RUN: %target-swift-frontend(mock-sdk: %clang-importer-sdk) -enable-objc-interop -emit-ir %s -validate-tbd-against-ir=all | %FileCheck %s
// REQUIRES: objc_interop
import Foundation
public class Foo {
// CHECK-LABEL: define linkonce_odr hidden swiftcc ptr @"$sSo8NSNumberC5valueABSi_tcfC"
// CHECK-LABEL: define linkonce_odr hidden swiftcc ptr @"$sSo8NSNumberC5valueABSi_tcfcTO"
public var bar: NSNumber = NSNumber(value: 1)
}