diff options
author | Kazu Hirata <kazu@google.com> | 2020-07-23 23:13:44 -0700 |
---|---|---|
committer | Kazu Hirata <kazu@google.com> | 2020-07-27 10:20:44 -0700 |
commit | 902cbcd59e22ccd853f6b0c22acc772fd955dc46 (patch) | |
tree | f6afaebe99908e2b8cec30618233d306ade6a690 /llvm/tools/llvm-exegesis/lib/Analysis.cpp | |
parent | df880b77302d2e12d988e620eba242defdd6d4a7 (diff) | |
download | llvm-902cbcd59e22ccd853f6b0c22acc772fd955dc46.zip llvm-902cbcd59e22ccd853f6b0c22acc772fd955dc46.tar.gz llvm-902cbcd59e22ccd853f6b0c22acc772fd955dc46.tar.bz2 |
Use llvm::is_contained where appropriate (NFC)
Summary:
This patch replaces std::find with llvm::is_contained where
appropriate.
Reviewers: efriedma, nhaehnle
Reviewed By: nhaehnle
Subscribers: arsenm, jvesely, nhaehnle, hiraditya, rogfer01, kerbowa, llvm-commits, vkmr
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D84489
Diffstat (limited to 'llvm/tools/llvm-exegesis/lib/Analysis.cpp')
-rw-r--r-- | llvm/tools/llvm-exegesis/lib/Analysis.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/tools/llvm-exegesis/lib/Analysis.cpp b/llvm/tools/llvm-exegesis/lib/Analysis.cpp index 5e9023b..077acf9 100644 --- a/llvm/tools/llvm-exegesis/lib/Analysis.cpp +++ b/llvm/tools/llvm-exegesis/lib/Analysis.cpp @@ -28,7 +28,7 @@ enum EscapeTag { kEscapeCsv, kEscapeHtml, kEscapeHtmlString }; template <EscapeTag Tag> void writeEscaped(raw_ostream &OS, const StringRef S); template <> void writeEscaped<kEscapeCsv>(raw_ostream &OS, const StringRef S) { - if (std::find(S.begin(), S.end(), kCsvSep) == S.end()) { + if (!llvm::is_contained(S, kCsvSep)) { OS << S; } else { // Needs escaping. |