hubert.reinterpretcast added inline comments.
================ Comment at: clang/lib/Sema/SemaDeclCXX.cpp:16867-16868 +/// Convert character's code unit value to a string. +/// The code point needs to be zero-extended to 32-bits. +static void WriteCharValueForDiagnostic(uint32_t Value, const BuiltinType *BTy, ---------------- Suggest wording tweaks. ================ Comment at: clang/lib/Sema/SemaDeclCXX.cpp:16894-16895 + if (llvm::ConvertCodePointToUTF8(Value, Ptr)) { + for (char *I = Arr; I != Ptr; ++I) + OS << *I; + } else { ---------------- Try using `StringRef`. ================ Comment at: clang/lib/Sema/SemaDeclCXX.cpp:16897 + } else { + // FIXME: This assumes Unicode literal encodings + OS << "\\x" ---------------- Since the function interface has been clarified, this part actually doesn't need a FIXME. The FIXME should instead be added to the comment above the function declaration. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D155610/new/ https://reviews.llvm.org/D155610 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits