clang-format: Add @s when breaking NSString literals.
While it is allowed to not have an @ on subsequent lines, it seems
general practice to add them. If undesired, the code author can easily
remove them again and clang-format won't re-add them.
llvm-svn: 198871
diff --git a/clang/unittests/Format/FormatTest.cpp b/clang/unittests/Format/FormatTest.cpp
index 22b2703..c66dd98 100644
--- a/clang/unittests/Format/FormatTest.cpp
+++ b/clang/unittests/Format/FormatTest.cpp
@@ -6239,7 +6239,7 @@
format("#define A \"some text other\";", AlignLeft));
}
-TEST_F(FormatTest, BreaksWideStringLiterals) {
+TEST_F(FormatTest, BreaksWideAndNSStringLiterals) {
EXPECT_EQ(
"u8\"utf8 string \"\n"
"u8\"literal\";",
@@ -6255,6 +6255,9 @@
EXPECT_EQ("L\"wide string \"\n"
"L\"literal\";",
format("L\"wide string literal\";", getGoogleStyleWithColumns(16)));
+ EXPECT_EQ("@\"NSString \"\n"
+ "@\"literal\";",
+ format("@\"NSString literal\";", getGoogleStyleWithColumns(16)));
}
TEST_F(FormatTest, BreaksRawStringLiterals) {