diff options
author | Fangrui Song <maskray@google.com> | 2019-02-10 05:54:57 +0000 |
---|---|---|
committer | Fangrui Song <maskray@google.com> | 2019-02-10 05:54:57 +0000 |
commit | 9ac13a12443b24e877e2b2cee128bdd41e3d67c8 (patch) | |
tree | 5eeeb91b169e5216069605596dbb1c25d8c6805d /clang/lib/ARCMigrate | |
parent | 609d676aab5a04a1f53992e73f7ca52f7ea589ff (diff) | |
download | bcm5719-llvm-9ac13a12443b24e877e2b2cee128bdd41e3d67c8.tar.gz bcm5719-llvm-9ac13a12443b24e877e2b2cee128bdd41e3d67c8.zip |
Use llvm::is_contained. NFC
llvm-svn: 353635
Diffstat (limited to 'clang/lib/ARCMigrate')
-rw-r--r-- | clang/lib/ARCMigrate/ARCMT.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/ARCMigrate/ARCMT.cpp b/clang/lib/ARCMigrate/ARCMT.cpp index d057dfcdf96..a0b9dc0f2e3 100644 --- a/clang/lib/ARCMigrate/ARCMT.cpp +++ b/clang/lib/ARCMigrate/ARCMT.cpp @@ -35,10 +35,10 @@ bool CapturedDiagList::clearDiagnostic(ArrayRef<unsigned> IDs, while (I != List.end()) { FullSourceLoc diagLoc = I->getLocation(); if ((IDs.empty() || // empty means clear all diagnostics in the range. - std::find(IDs.begin(), IDs.end(), I->getID()) != IDs.end()) && + llvm::is_contained(IDs, I->getID())) && !diagLoc.isBeforeInTranslationUnitThan(range.getBegin()) && (diagLoc == range.getEnd() || - diagLoc.isBeforeInTranslationUnitThan(range.getEnd()))) { + diagLoc.isBeforeInTranslationUnitThan(range.getEnd()))) { cleared = true; ListTy::iterator eraseS = I++; if (eraseS->getLevel() != DiagnosticsEngine::Note) |