MyDeveloperDay added inline comments.
================ Comment at: clang/lib/Format/BreakableToken.cpp:199 + if (EscapeSequence && Advance == 2) { + switch (Text[1]) { ---------------- sstwcw wrote: > MyDeveloperDay wrote: > > Can we add a unit test for escape sequences > \X which I assume this handles > There are already tests that verify that the string does not get broken > inside an escape sequence in `BreaksWideAndNSStringLiterals` and > `DoNotBreakStringLiteralsInEscapeSequence`. And escape sequences longer than > 1 character following the backslash should not begin with one of these > letters. So I don't see what tests I should add. I was thinking about your tests having a test case which shows it shouldn't break, in case someone add case 'x' into your code, i.e. asserting the negative. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154091/new/ https://reviews.llvm.org/D154091 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits