[PATCH] D124341: [clang-tidy][NFC] Replace many instances of std::string where a StringRef would suffice.

Aaron Ballman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed May 4 04:03:51 PDT 2022


aaron.ballman accepted this revision.
aaron.ballman added a comment.
This revision is now accepted and ready to land.

In D124341#3476533 <https://reviews.llvm.org/D124341#3476533>, @njames93 wrote:

> In D124341#3475083 <https://reviews.llvm.org/D124341#3475083>, @aaron.ballman wrote:
>
>> I went through the changes and they look correct to me... yet I'm still mildly terrified. :-D Have you tried running clang-tidy through its paces with ASan/MSan enabled to see if the change introduces any use-after-free issues in practice?
>
> I can't seem to build LLVM with msan at all. But ASan, which checks things like use after free, ran all clang tools tests without a hitch.

Thanks for checking! I've convinced myself that I don't see any lifetime issues here (in each case, what the `StringRef` refers to should outlive the `StringRef`), so this LGTM.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D124341



More information about the cfe-commits mailing list