cmMakefile: Use std::set::insert API to simplify CMP0054 handling.

This commit is contained in:
Stephen Kelly 2015-05-18 21:41:42 +02:00
parent f9785e0cb6
commit 7eb0dfa062
1 changed files with 1 additions and 9 deletions

View File

@ -4945,15 +4945,7 @@ bool cmMakefile::HasCMP0054AlreadyBeenReported() const
{ {
cmCMP0054Id id(this->GetExecutionContext()); cmCMP0054Id id(this->GetExecutionContext());
bool alreadyReported = return !this->CMP0054ReportedIds.insert(id).second;
this->CMP0054ReportedIds.find(id) != this->CMP0054ReportedIds.end();
if(!alreadyReported)
{
this->CMP0054ReportedIds.insert(id);
}
return alreadyReported;
} }
//---------------------------------------------------------------------------- //----------------------------------------------------------------------------