[PATCH] D157010: [llvm][ADT] Make `Twine` aware of `StringLiteral`

Ben Langmuir via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 3 09:28:51 PDT 2023


benlangmuir added a comment.

I could be mistaken, but I think this is the same as the std::string case -- a combination of already null-terminated (so no allocation) and having a length, so no need to strlen in the StringRef constructors.

Would it make sense to combine them into a single NullTerminatedPtrAndLength representation?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D157010



More information about the llvm-commits mailing list