diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx index 1de4a5976..c976c699b 100644 --- a/Source/cmGlobalGenerator.cxx +++ b/Source/cmGlobalGenerator.cxx @@ -2937,14 +2937,11 @@ void cmGlobalGenerator::WriteSummary(cmTarget* target) { target->GetSourceFiles(sources, *ci); } - std::set emitted; + std::vector::const_iterator sourcesEnd + = cmRemoveDuplicates(sources); for(std::vector::const_iterator si = sources.begin(); - si != sources.end(); ++si) + si != sourcesEnd; ++si) { - if (!emitted.insert(*si).second) - { - continue; - } Json::Value& lj_source = lj_sources.append(Json::objectValue); cmSourceFile* sf = *si; std::string const& sfp = sf->GetFullPath();