mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Preserve the AbstractCC of a function symbol when emitting a SIL ConstantRefInst by adding a new StaticFunction variant to LoweredValue. This lets us avoid a bunch of bitcasting noise for static functions that aren't used as values, and will lets us emit C-to-Swift-ABI thunks on demand when C functions are used as values. Swift SVN r4543
10 lines
297 B
Swift
10 lines
297 B
Swift
// RUN: rm -rf %t/clang-module-cache
|
|
// RUN: %swift -module-cache-path=%t/clang-module-cache -sdk=%sdk -i %s | FileCheck %s
|
|
// RUN: %swift -module-cache-path=%t/clang-module-cache -sdk=%sdk -sil-irgen -i %s | FileCheck %s
|
|
// REQUIRES: sdk
|
|
|
|
import Darwin
|
|
|
|
// CHECK: Hello world
|
|
puts("Hello world")
|