[PATCH] D150426: [llvm] Migrate {starts,ends}with_insensitive to {starts,ends}_with_insensitive (NFC)
Kazu Hirata via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri May 12 11:04:33 PDT 2023
kazu added a comment.
In D150426#4338495 <https://reviews.llvm.org/D150426#4338495>, @MaskRay wrote:
> In D150426#4338475 <https://reviews.llvm.org/D150426#4338475>, @dblaikie wrote:
>
>> I should check - are these function names actually in std::string_view? It doesn't look like it, so renaming them doesn't help us get to the ability to switch to std::string_view, right?
>>
>> Maybe it'd make more sense to make these non-member functions, so the StringRef API gets closer to string_view?
>
> `std::string_view::starts_with_insensitive` doesn't exist. It (including `startswith_insensitive`) is a StringRef extension that occurs ~80 times in llvm-project.
>
> (@aaron.ballman)
Yes, `startswith_insensitive` is a `StringRef` extension.
We should probably tackle `StringRef::startswith` and `StringRef::endswith` also, but I'd consult larger audience as they are used in a lot more places.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D150426/new/
https://reviews.llvm.org/D150426
More information about the llvm-commits
mailing list