summaryrefslogtreecommitdiffstats
path: root/clang/lib/ARCMigrate
diff options
context:
space:
mode:
authorFangrui Song <maskray@google.com>2019-02-10 05:54:57 +0000
committerFangrui Song <maskray@google.com>2019-02-10 05:54:57 +0000
commit9ac13a12443b24e877e2b2cee128bdd41e3d67c8 (patch)
tree5eeeb91b169e5216069605596dbb1c25d8c6805d /clang/lib/ARCMigrate
parent609d676aab5a04a1f53992e73f7ca52f7ea589ff (diff)
downloadbcm5719-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.cpp4
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)
OpenPOWER on IntegriCloud