diff options
author | Stephen Kelly <steveire@gmail.com> | 2013-07-14 16:22:57 (GMT) |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2014-01-09 18:38:08 (GMT) |
commit | 531e40b95e80fbf5547b0a8d71196e819bb3aa3d (patch) | |
tree | c1b9f09d329496f511135c9665275e8fc21f6ccf /Source/cmGeneratorTarget.cxx | |
parent | 38de54cf6f3daae70792fae1bf26b97bccc78de4 (diff) | |
download | CMake-531e40b95e80fbf5547b0a8d71196e819bb3aa3d.zip CMake-531e40b95e80fbf5547b0a8d71196e819bb3aa3d.tar.gz CMake-531e40b95e80fbf5547b0a8d71196e819bb3aa3d.tar.bz2 |
cmTarget: Make GetSourceFiles populate an out-vector parameter.
In a future patch, this will also be populated with extra
sources from the linked dependencies.
Diffstat (limited to 'Source/cmGeneratorTarget.cxx')
-rw-r--r-- | Source/cmGeneratorTarget.cxx | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx index 88f533c..5cd1f42 100644 --- a/Source/cmGeneratorTarget.cxx +++ b/Source/cmGeneratorTarget.cxx @@ -284,9 +284,9 @@ bool cmGeneratorTarget::GetPropertyAsBool(const char *prop) const } //---------------------------------------------------------------------------- -std::vector<cmSourceFile*> const& cmGeneratorTarget::GetSourceFiles() const +void cmGeneratorTarget::GetSourceFiles(std::vector<cmSourceFile*> &files) const { - return this->Target->GetSourceFiles(); + this->Target->GetSourceFiles(files); } //---------------------------------------------------------------------------- @@ -298,7 +298,8 @@ void cmGeneratorTarget::ClassifySources() bool isObjLib = targetType == cmTarget::OBJECT_LIBRARY; std::vector<cmSourceFile*> badObjLib; - std::vector<cmSourceFile*> const& sources = this->Target->GetSourceFiles(); + std::vector<cmSourceFile*> sources; + this->Target->GetSourceFiles(sources); for(std::vector<cmSourceFile*>::const_iterator si = sources.begin(); si != sources.end(); ++si) { @@ -496,7 +497,8 @@ cmTargetTraceDependencies this->CurrentEntry = 0; // Queue all the source files already specified for the target. - std::vector<cmSourceFile*> const& sources = this->Target->GetSourceFiles(); + std::vector<cmSourceFile*> sources; + this->Target->GetSourceFiles(sources); for(std::vector<cmSourceFile*>::const_iterator si = sources.begin(); si != sources.end(); ++si) { |