Files
swift-mirror/test/Interpreter/lazy/linkage_promotion.swift
Nate Chandler 4e22193d9e [Test] Require asserts for some experimental-feature tests.
For LazyImmediate and TupleConformances.
2023-08-24 13:46:35 -07:00

24 lines
486 B
Swift

// REQUIRES: OS=macosx
// REQUIRES: swift_interpreter
// RUN: %target-jit-run %s -enable-experimental-feature LazyImmediate | %FileCheck %s
// -enable-experimental-feature requires an asserts build
// REQUIRES: asserts
// Tests that the linkage of private symbols is
// promoted to hidden external, allowing
// single-function compilation of non-public symbols.
fileprivate func foo() {
print("foo")
}
func bar() {
foo()
print("bar")
}
// CHECK: foo
// CHECK-NEXT: bar
bar()