[all-commits] [llvm/llvm-project] 135d92: [Driver] Use StringRef::operator== instead of Stri...
Kazu Hirata via All-commits
all-commits at lists.llvm.org
Thu May 9 23:12:30 PDT 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 135d92f903161e66ff82ab846acfbc5015ef3096
https://github.com/llvm/llvm-project/commit/135d92f903161e66ff82ab846acfbc5015ef3096
Author: Kazu Hirata <kazu at google.com>
Date: 2024-05-09 (Thu, 09 May 2024)
Changed paths:
M clang/lib/Driver/Driver.cpp
M clang/lib/Driver/ToolChains/AIX.cpp
M clang/lib/Driver/ToolChains/AMDGPU.cpp
M clang/lib/Driver/ToolChains/Clang.cpp
M clang/lib/Driver/ToolChains/CommonArgs.cpp
M clang/lib/Driver/ToolChains/Flang.cpp
Log Message:
-----------
[Driver] Use StringRef::operator== instead of StringRef::equals (NFC) (#91698)
I'm planning to remove StringRef::equals in favor of
StringRef::operator==.
- StringRef::operator==/!= outnumber StringRef::equals by a factor of
13 under clang/ in terms of their usage.
- The elimination of StringRef::equals brings StringRef closer to
std::string_view, which has operator== but not equals.
- S == "foo" is more readable than S.equals("foo"), especially for
!Long.Expression.equals("str") vs Long.Expression != "str".
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list