summaryrefslogtreecommitdiffstats
path: root/Source/cmTarget.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2016-09-15 20:00:24 (GMT)
committerBrad King <brad.king@kitware.com>2016-09-15 20:02:27 (GMT)
commit9353d991a4a9df1c7bdededaf0b11fc96227f805 (patch)
treea3f3079c8bd22b9e5c0631c1c59d4ac6112a8cc9 /Source/cmTarget.cxx
parentfa3897b24eb9a5cbc4926659b11f8cb6087789a1 (diff)
downloadCMake-9353d991a4a9df1c7bdededaf0b11fc96227f805.zip
CMake-9353d991a4a9df1c7bdededaf0b11fc96227f805.tar.gz
CMake-9353d991a4a9df1c7bdededaf0b11fc96227f805.tar.bz2
cmTarget: Remove unused support for partial construction
We no longer need to support partial construction for cmTarget instances of type GLOBAL_TARGET. Require all constructor arguments up front.
Diffstat (limited to 'Source/cmTarget.cxx')
-rw-r--r--Source/cmTarget.cxx23
1 files changed, 2 insertions, 21 deletions
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx
index d964f00..1b6c93e 100644
--- a/Source/cmTarget.cxx
+++ b/Source/cmTarget.cxx
@@ -62,10 +62,10 @@ public:
cmTarget::cmTarget(std::string const& name, cmState::TargetType type,
Visibility vis, cmMakefile* mf)
{
- assert(mf || type == cmState::GLOBAL_TARGET);
+ assert(mf);
this->Name = name;
this->TargetTypeValue = type;
- this->Makefile = CM_NULLPTR;
+ this->Makefile = mf;
this->HaveInstallRule = false;
this->DLLPlatform = false;
this->IsAndroid = false;
@@ -82,25 +82,6 @@ cmTarget::cmTarget(std::string const& name, cmState::TargetType type,
this->RecordDependencies = false;
}
- if (mf) {
- this->SetMakefile(mf);
- }
-}
-
-cmTarget cmTarget::CopyForDirectory(cmMakefile* mf) const
-{
- assert(this->GetType() == cmState::GLOBAL_TARGET);
- assert(this->GetMakefile() == CM_NULLPTR);
- cmTarget result(*this);
- result.SetMakefile(mf);
- return result;
-}
-
-void cmTarget::SetMakefile(cmMakefile* mf)
-{
- // Set our makefile.
- this->Makefile = mf;
-
// Check whether this is a DLL platform.
this->DLLPlatform =
(this->Makefile->IsOn("WIN32") || this->Makefile->IsOn("CYGWIN") ||