[PATCH] D138861: [Clang] Implement CWG2640 Allow more characters in an n-char sequence

Tom Honermann via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Dec 9 13:56:11 PST 2022


tahonermann added inline comments.


================
Comment at: clang/lib/Lex/Lexer.cpp:3323
     if (Diagnose)
       Diag(StartPtr, diag::warn_ucn_escape_incomplete);
     return llvm::None;
----------------
I was able to confirm that `StartPtr` does point to `N`. See the diagnostic generated at https://godbolt.org/z/qnajcMeso; the diagnostic caret points to `N` instead of `\`.
  <source>:1:2: warning: incomplete delimited universal character name; treating as '\' 'N' '{' identifier [-Wunicode]
  \N{abc
   ^


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D138861/new/

https://reviews.llvm.org/D138861



More information about the cfe-commits mailing list