[PATCH] D108469: Improve handling of static assert messages.

Corentin Jabot via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Sep 30 05:59:07 PDT 2021


cor3ntin added inline comments.


================
Comment at: clang/lib/Basic/Diagnostic.cpp:792
+static void pushEscapedString(StringRef Str, SmallVectorImpl<char> &OutStr) {
+  OutStr.reserve(OutStr.size() + Str.size());
+  const unsigned char *Begin =
----------------
jfb wrote:
> Can this addition overflow?
Technically yes, if you are trying to output a single string over 4GB I guess. Do we care?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D108469



More information about the cfe-commits mailing list