Simplify use of binary_search.

A local string was created when dir was a const char*. Now dir is a
std::string already so the dirString is vestigal.
This commit is contained in:
Stephen Kelly 2014-08-06 15:20:24 +02:00
parent 1927e4bacb
commit 80bda1684d
1 changed files with 1 additions and 3 deletions

View File

@ -519,9 +519,7 @@ bool cmGeneratorTarget::IsSystemIncludeDirectory(const std::string& dir,
iter = this->SystemIncludesCache.insert(entry).first;
}
std::string dirString = dir;
return std::binary_search(iter->second.begin(), iter->second.end(),
dirString);
return std::binary_search(iter->second.begin(), iter->second.end(), dir);
}
//----------------------------------------------------------------------------