Merge topic 'constify'
f054201d
cmMakefile: Return containers by const reference.d1ac6ffd
cmMakefile: Fix minor indentation inconsistency.
This commit is contained in:
commit
6e43138c3f
|
@ -1570,23 +1570,23 @@ void cmMakefile::InitializeFromParent()
|
||||||
// Initialize definitions with the closure of the parent scope.
|
// Initialize definitions with the closure of the parent scope.
|
||||||
this->Internal->VarStack.top() = parent->Internal->VarStack.top().Closure();
|
this->Internal->VarStack.top() = parent->Internal->VarStack.top().Closure();
|
||||||
|
|
||||||
const std::vector<cmValueWithOrigin> parentIncludes =
|
const std::vector<cmValueWithOrigin>& parentIncludes =
|
||||||
parent->GetIncludeDirectoriesEntries();
|
parent->GetIncludeDirectoriesEntries();
|
||||||
this->IncludeDirectoriesEntries.insert(this->IncludeDirectoriesEntries.end(),
|
this->IncludeDirectoriesEntries.insert(this->IncludeDirectoriesEntries.end(),
|
||||||
parentIncludes.begin(),
|
parentIncludes.begin(),
|
||||||
parentIncludes.end());
|
parentIncludes.end());
|
||||||
|
|
||||||
const std::vector<cmValueWithOrigin> parentOptions =
|
const std::vector<cmValueWithOrigin>& parentOptions =
|
||||||
parent->GetCompileOptionsEntries();
|
parent->GetCompileOptionsEntries();
|
||||||
this->CompileOptionsEntries.insert(this->CompileOptionsEntries.end(),
|
this->CompileOptionsEntries.insert(this->CompileOptionsEntries.end(),
|
||||||
parentOptions.begin(),
|
parentOptions.begin(),
|
||||||
parentOptions.end());
|
parentOptions.end());
|
||||||
|
|
||||||
const std::vector<cmValueWithOrigin> parentDefines =
|
const std::vector<cmValueWithOrigin>& parentDefines =
|
||||||
parent->GetCompileDefinitionsEntries();
|
parent->GetCompileDefinitionsEntries();
|
||||||
this->CompileDefinitionsEntries.insert(this->CompileDefinitionsEntries.end(),
|
this->CompileDefinitionsEntries.insert(this->CompileDefinitionsEntries.end(),
|
||||||
parentDefines.begin(),
|
parentDefines.begin(),
|
||||||
parentDefines.end());
|
parentDefines.end());
|
||||||
|
|
||||||
this->SystemIncludeDirectories = parent->SystemIncludeDirectories;
|
this->SystemIncludeDirectories = parent->SystemIncludeDirectories;
|
||||||
|
|
||||||
|
|
|
@ -853,15 +853,15 @@ public:
|
||||||
/** Set whether or not to report a CMP0000 violation. */
|
/** Set whether or not to report a CMP0000 violation. */
|
||||||
void SetCheckCMP0000(bool b) { this->CheckCMP0000 = b; }
|
void SetCheckCMP0000(bool b) { this->CheckCMP0000 = b; }
|
||||||
|
|
||||||
std::vector<cmValueWithOrigin> GetIncludeDirectoriesEntries() const
|
const std::vector<cmValueWithOrigin>& GetIncludeDirectoriesEntries() const
|
||||||
{
|
{
|
||||||
return this->IncludeDirectoriesEntries;
|
return this->IncludeDirectoriesEntries;
|
||||||
}
|
}
|
||||||
std::vector<cmValueWithOrigin> GetCompileOptionsEntries() const
|
const std::vector<cmValueWithOrigin>& GetCompileOptionsEntries() const
|
||||||
{
|
{
|
||||||
return this->CompileOptionsEntries;
|
return this->CompileOptionsEntries;
|
||||||
}
|
}
|
||||||
std::vector<cmValueWithOrigin> GetCompileDefinitionsEntries() const
|
const std::vector<cmValueWithOrigin>& GetCompileDefinitionsEntries() const
|
||||||
{
|
{
|
||||||
return this->CompileDefinitionsEntries;
|
return this->CompileDefinitionsEntries;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue