mirror of
https://gitlab.kitware.com/cmake/cmake.git
synced 2026-10-12 23:43:59 +03:00
cmMakefile: Use std::set::insert API to simplify CMP0054 handling.
This commit is contained in:
1 parent
f9785e0cb6
commit
7eb0dfa062
1 file changed
+1
-9
@@ -4945,15 +4945,7 @@ bool cmMakefile::HasCMP0054AlreadyBeenReported() const
|
||||
{
|
||||
cmCMP0054Id id(this->GetExecutionContext());
|
||||
|
||||
bool alreadyReported =
|
||||
this->CMP0054ReportedIds.find(id) != this->CMP0054ReportedIds.end();
|
||||
|
||||
if(!alreadyReported)
|
||||
{
|
||||
this->CMP0054ReportedIds.insert(id);
|
||||
}
|
||||
|
||||
return alreadyReported;
|
||||
return !this->CMP0054ReportedIds.insert(id).second;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
|
||||
Reference in new issue
Block a user