[clang] [Format] Do not crash on non-null terminated strings (PR #131299)
Ilya Biryukov via cfe-commits
cfe-commits at lists.llvm.org
Mon Mar 24 04:19:49 PDT 2025
================
@@ -29096,6 +29096,17 @@ TEST_F(FormatTest, BreakBeforeClassName) {
" ArenaSafeUniquePtr {};");
}
+TEST_F(FormatTest, DoesNotCrashOnNonNullTerminatedStringRefs) {
+ llvm::StringRef TwoLines = "namespace foo {}\n"
----------------
ilya-biryukov wrote:
Done. Thanks!
https://github.com/llvm/llvm-project/pull/131299
More information about the cfe-commits
mailing list