Files
swift-mirror/test/SIL/Parser/string_literal.sil
Arnold Schwaighofer b167b4475d Add SIL and IRGen support for a ConstantStringLiteral instruction
This supports a utf8 or utf16 encoding.

rdar://30545013
2017-04-11 08:43:47 -07:00

14 lines
450 B
Plaintext

// RUN: %target-sil-opt -assume-parsing-unqualified-ownership-sil %s
sil @test : $@convention(thin) () -> () {
bb0:
// CHECK: string_literal utf8 "\u{0B}"
%1 = string_literal utf8 "\u{0B}"
// CHECK: const_string_literal utf8 "\u{0B}"
%2 = const_string_literal utf8 "\u{0B}"
// CHECK: const_string_literal utf16 "\u{0B}"
%3 = const_string_literal utf16 "\u{0B}"
%6 = tuple () // user: %7
return %6 : $()
}