summaryrefslogtreecommitdiffstats
path: root/llvm/tools/bugpoint
diff options
context:
space:
mode:
authorDavid Majnemer <david.majnemer@gmail.com>2016-08-11 22:21:41 +0000
committerDavid Majnemer <david.majnemer@gmail.com>2016-08-11 22:21:41 +0000
commit0d955d0bf5cbbd50061309ad2c08c0dcf8f62039 (patch)
tree19991ceb4f16b4e3ce06fe2c39304d27a93b8b7b /llvm/tools/bugpoint
parent332b3b22109e9c0d84456888150c0a30f378f984 (diff)
downloadbcm5719-llvm-0d955d0bf5cbbd50061309ad2c08c0dcf8f62039.tar.gz
bcm5719-llvm-0d955d0bf5cbbd50061309ad2c08c0dcf8f62039.zip
Use the range variant of find instead of unpacking begin/end
If the result of the find is only used to compare against end(), just use is_contained instead. No functionality change is intended. llvm-svn: 278433
Diffstat (limited to 'llvm/tools/bugpoint')
-rw-r--r--llvm/tools/bugpoint/CrashDebugger.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/llvm/tools/bugpoint/CrashDebugger.cpp b/llvm/tools/bugpoint/CrashDebugger.cpp
index c5ceba6f5a6..f6b35f5fd53 100644
--- a/llvm/tools/bugpoint/CrashDebugger.cpp
+++ b/llvm/tools/bugpoint/CrashDebugger.cpp
@@ -239,9 +239,7 @@ static void RemoveFunctionReferences(Module *M, const char* Name) {
bool ReduceCrashingFunctions::TestFuncs(std::vector<Function*> &Funcs) {
// If main isn't present, claim there is no problem.
- if (KeepMain && std::find(Funcs.begin(), Funcs.end(),
- BD.getProgram()->getFunction("main")) ==
- Funcs.end())
+ if (KeepMain && !is_contained(Funcs, BD.getProgram()->getFunction("main")))
return false;
// Clone the program to try hacking it apart...
OpenPOWER on IntegriCloud