clang-format: Fix crasher on weird comments.
Crashing input:
/\
/ comment
llvm-svn: 226454
diff --git a/clang/unittests/Format/FormatTest.cpp b/clang/unittests/Format/FormatTest.cpp
index f267c94..615b46a 100644
--- a/clang/unittests/Format/FormatTest.cpp
+++ b/clang/unittests/Format/FormatTest.cpp
@@ -1035,6 +1035,9 @@
" // spanning two lines\n"
" x + 3) {\n"
"}"));
+
+ verifyNoCrash("/\\\n/");
+ verifyNoCrash("/\\\n* */");
}
TEST_F(FormatTest, KeepsParameterWithTrailingCommentsOnTheirOwnLine) {