[llvm] [ADT] Deprecate StringRef::equals (PR #92351)
Fangrui Song via llvm-commits
llvm-commits at lists.llvm.org
Thu May 16 00:06:29 PDT 2024
================
@@ -161,7 +161,9 @@ namespace llvm {
/// equals - Check for string equality, this is more efficient than
/// compare() when the relative ordering of inequal strings isn't needed.
- [[nodiscard]] bool equals(StringRef RHS) const {
+ [[nodiscard]] LLVM_DEPRECATED(
+ "Use operator==(StringRef, StringRef) instead",
----------------
MaskRay wrote:
Perhaps just `Use == instead`.
We don't expect users to write `operator==`
https://github.com/llvm/llvm-project/pull/92351
More information about the llvm-commits
mailing list