mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
This re-instates commit cc9e53bb08 with a fix for LLDB (rdar://124228107)
rdar://123772098
23 lines
969 B
Swift
23 lines
969 B
Swift
// RUN: %target-run-simple-swift(-enable-experimental-feature Embedded -parse-as-library -runtime-compatibility-version none -wmo -Xfrontend -disable-objc-interop) | %FileCheck %s
|
|
// RUN: %target-run-simple-swift(-O -enable-experimental-feature Embedded -parse-as-library -runtime-compatibility-version none -wmo -Xfrontend -disable-objc-interop) | %FileCheck %s
|
|
// RUN: %target-run-simple-swift(-O -lto=llvm-full %lto_flags -enable-experimental-feature Embedded -parse-as-library -runtime-compatibility-version none -wmo -Xfrontend -disable-objc-interop) | %FileCheck %s
|
|
|
|
// REQUIRES: swift_in_compiler
|
|
// REQUIRES: executable_test
|
|
// REQUIRES: optimized_stdlib
|
|
// REQUIRES: OS=macosx || OS=linux-gnu
|
|
|
|
// Check that initializing a Double with an integer literal doesn't result in unresolved symbols
|
|
@inline(never)
|
|
func testLiteral() -> Double {
|
|
return Double(1)
|
|
}
|
|
|
|
@main
|
|
struct Main {
|
|
static func main() {
|
|
print(testLiteral() == 1.0)
|
|
// CHECK: true
|
|
}
|
|
}
|