mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
This reverts commit062d14b422. Revert "Fix a swift argument initialization bug - swift argument should be initialized" This reverts commit273b149583. This breaks DebugAssert as well as REPL builds. Revert to appease the bots while i look further.
22 lines
856 B
Swift
22 lines
856 B
Swift
// RUN: %target-swift-frontend -primary-file %s -emit-ir -parse-stdlib -disable-access-control | FileCheck %s
|
|
|
|
// REQUIRES: CPU=x86_64
|
|
|
|
import Swift
|
|
|
|
|
|
// CHECK: private unnamed_addr constant [22 x i8] c"this is just a\0A\0A test\00"
|
|
|
|
// CHECK: define hidden [[stringLayout:[^@]*]] @_TF11expressions17TestStringLiteralFT_SS() {{.*}} {
|
|
// CHECK: call [[stringLayout]] @{{.*}}_builtinStringLiteral{{.*}}(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @0, i64 0, i64 0), i64 21, i1 true)
|
|
|
|
func TestStringLiteral() -> String {
|
|
return "this is just a\n\u{0a} test"
|
|
}
|
|
|
|
// CHECK: define hidden [[stringLayout]] @_TF11expressions18TestStringLiteral2FT_SS() {{.*}} {
|
|
// CHECK: call [[stringLayout]] @{{.*}}_builtinUTF16StringLiteral{{.*}}(i8* bitcast ([19 x i16]* @1 to i8*), i64 18)
|
|
func TestStringLiteral2() -> String {
|
|
return "non-ASCII string \u{00B5}"
|
|
}
|