only use each include path once
This commit is contained in:
parent
947ace6194
commit
cde17935ea
|
@ -122,7 +122,12 @@ static bool simplifyPathWithVariables(std::string &s, const std::map<std::string
|
|||
void ImportProject::FileSettings::setIncludePaths(const std::string &basepath, const std::list<std::string> &in, const std::map<std::string, std::string> &variables)
|
||||
{
|
||||
std::list<std::string> I;
|
||||
for (std::list<std::string>::const_iterator it = in.begin(); it != in.end(); ++it) {
|
||||
// only parse each includePath once - so remove duplicates
|
||||
std::list<std::string> uniqueIncludePaths = in;
|
||||
uniqueIncludePaths.sort();
|
||||
uniqueIncludePaths.unique();
|
||||
|
||||
for (std::list<std::string>::const_iterator it = uniqueIncludePaths.begin(); uniqueIncludePaths != in.end(); ++it) {
|
||||
if (it->empty())
|
||||
continue;
|
||||
if (it->compare(0,2,"%(")==0)
|
||||
|
|
Loading…
Reference in New Issue