diff options
author | Brad King <brad.king@kitware.com> | 2017-04-27 20:21:37 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2017-04-27 20:21:59 (GMT) |
commit | 47990f9fef31eb4369bb01d72a6d86de332ae196 (patch) | |
tree | ac02d65dca9e73354f63804b9c920c8591b6be89 /Source | |
parent | a8667467ea6337faddb0eeb7a8d0b08154338ac0 (diff) | |
download | CMake-47990f9fef31eb4369bb01d72a6d86de332ae196.zip CMake-47990f9fef31eb4369bb01d72a6d86de332ae196.tar.gz CMake-47990f9fef31eb4369bb01d72a6d86de332ae196.tar.bz2 |
Inline and remove AddFeatureFlags method
The method implementation is now only one call of another method, so
inline it at call sites and remove it.
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmCommonTargetGenerator.cxx | 8 | ||||
-rw-r--r-- | Source/cmCommonTargetGenerator.h | 3 | ||||
-rw-r--r-- | Source/cmMakefileExecutableTargetGenerator.cxx | 6 | ||||
-rw-r--r-- | Source/cmMakefileLibraryTargetGenerator.cxx | 10 |
4 files changed, 10 insertions, 17 deletions
diff --git a/Source/cmCommonTargetGenerator.cxx b/Source/cmCommonTargetGenerator.cxx index 8114020..391d65c 100644 --- a/Source/cmCommonTargetGenerator.cxx +++ b/Source/cmCommonTargetGenerator.cxx @@ -43,14 +43,6 @@ const char* cmCommonTargetGenerator::GetFeature(const std::string& feature) return this->GeneratorTarget->GetFeature(feature, this->ConfigName); } -void cmCommonTargetGenerator::AddFeatureFlags(std::string& flags, - const std::string& lang) -{ - // Add language-specific flags. - this->LocalGenerator->AddLanguageFlags(flags, this->GeneratorTarget, lang, - this->ConfigName); -} - void cmCommonTargetGenerator::AddModuleDefinitionFlag( cmLinkLineComputer* linkLineComputer, std::string& flags) { diff --git a/Source/cmCommonTargetGenerator.h b/Source/cmCommonTargetGenerator.h index 8ba2e22..c36145f 100644 --- a/Source/cmCommonTargetGenerator.h +++ b/Source/cmCommonTargetGenerator.h @@ -28,9 +28,6 @@ public: std::string const& GetConfigName() const; protected: - // Add language feature flags. - void AddFeatureFlags(std::string& flags, const std::string& lang); - // Feature query methods. const char* GetFeature(const std::string& feature); diff --git a/Source/cmMakefileExecutableTargetGenerator.cxx b/Source/cmMakefileExecutableTargetGenerator.cxx index a719887..272d45b 100644 --- a/Source/cmMakefileExecutableTargetGenerator.cxx +++ b/Source/cmMakefileExecutableTargetGenerator.cxx @@ -150,7 +150,8 @@ void cmMakefileExecutableTargetGenerator::WriteDeviceExecutableRule( linkLanguage, *this->GeneratorTarget)); // Add language feature flags. - this->AddFeatureFlags(flags, linkLanguage); + this->LocalGenerator->AddLanguageFlags(flags, this->GeneratorTarget, + linkLanguage, this->ConfigName); this->LocalGenerator->AddArchitectureFlags(flags, this->GeneratorTarget, linkLanguage, this->ConfigName); @@ -433,7 +434,8 @@ void cmMakefileExecutableTargetGenerator::WriteExecutableRule(bool relink) } // Add language feature flags. - this->AddFeatureFlags(flags, linkLanguage); + this->LocalGenerator->AddLanguageFlags(flags, this->GeneratorTarget, + linkLanguage, this->ConfigName); this->LocalGenerator->AddArchitectureFlags(flags, this->GeneratorTarget, linkLanguage, this->ConfigName); diff --git a/Source/cmMakefileLibraryTargetGenerator.cxx b/Source/cmMakefileLibraryTargetGenerator.cxx index 2823977..ec01208 100644 --- a/Source/cmMakefileLibraryTargetGenerator.cxx +++ b/Source/cmMakefileLibraryTargetGenerator.cxx @@ -395,9 +395,10 @@ void cmMakefileLibraryTargetGenerator::WriteDeviceLibraryRules( vars.LinkFlags = linkFlags.c_str(); vars.TargetCompilePDB = targetOutPathCompilePDB.c_str(); - // Add language feature flags. + // Add language-specific flags. std::string langFlags; - this->AddFeatureFlags(langFlags, linkLanguage); + this->LocalGenerator->AddLanguageFlags(langFlags, this->GeneratorTarget, + linkLanguage, this->ConfigName); vars.LanguageCompileFlags = langFlags.c_str(); @@ -853,9 +854,10 @@ void cmMakefileLibraryTargetGenerator::WriteLibraryRules( } } - // Add language feature flags. + // Add language-specific flags. std::string langFlags; - this->AddFeatureFlags(langFlags, linkLanguage); + this->LocalGenerator->AddLanguageFlags(langFlags, this->GeneratorTarget, + linkLanguage, this->ConfigName); this->LocalGenerator->AddArchitectureFlags( langFlags, this->GeneratorTarget, linkLanguage, this->ConfigName); |