diff options
author | David Majnemer <david.majnemer@gmail.com> | 2016-08-11 22:21:41 +0000 |
---|---|---|
committer | David Majnemer <david.majnemer@gmail.com> | 2016-08-11 22:21:41 +0000 |
commit | 975248e4fb3ddeb2fcf743d56492494feeb803a1 (patch) | |
tree | 4105e6d070c6472d6152f3b85bfef3612f9e6bd1 /tools/bugpoint/CrashDebugger.cpp | |
parent | fb2a7f990d60e9f97008cae87d9848c244c15311 (diff) |
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.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@278433 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/bugpoint/CrashDebugger.cpp')
-rw-r--r-- | tools/bugpoint/CrashDebugger.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/tools/bugpoint/CrashDebugger.cpp b/tools/bugpoint/CrashDebugger.cpp index c5ceba6f5a6..f6b35f5fd53 100644 --- a/tools/bugpoint/CrashDebugger.cpp +++ b/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... |