diff options
author | Brad King <brad.king@kitware.com> | 2022-11-30 12:27:10 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2022-11-30 12:28:12 (GMT) |
commit | 3b19541518d96fe803b26d4f20a23b71005af41c (patch) | |
tree | 3dbc83a2beeddeea16cf9cb4204e65148f9fd212 /Source/cmGeneratorTarget.h | |
parent | d871fad90241df2b58b55c816554a1ef2ccf6a79 (diff) | |
parent | f69d1872dbddb81f73d9f1dac98def9ee153ea9f (diff) | |
download | CMake-3b19541518d96fe803b26d4f20a23b71005af41c.zip CMake-3b19541518d96fe803b26d4f20a23b71005af41c.tar.gz CMake-3b19541518d96fe803b26d4f20a23b71005af41c.tar.bz2 |
Merge topic 'add-generator-target-caches'
f69d1872db cmGeneratorTarget: Add caches to some functions
Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !7952
Diffstat (limited to 'Source/cmGeneratorTarget.h')
-rw-r--r-- | Source/cmGeneratorTarget.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/Source/cmGeneratorTarget.h b/Source/cmGeneratorTarget.h index 96eda2c..3cd5e34 100644 --- a/Source/cmGeneratorTarget.h +++ b/Source/cmGeneratorTarget.h @@ -490,6 +490,18 @@ public: std::string GetCreateRuleVariable(std::string const& lang, std::string const& config) const; +private: + using ConfigAndLanguage = std::pair<std::string, std::string>; + using ConfigAndLanguageToBTStrings = + std::map<ConfigAndLanguage, std::vector<BT<std::string>>>; + mutable ConfigAndLanguageToBTStrings IncludeDirectoriesCache; + mutable ConfigAndLanguageToBTStrings CompileOptionsCache; + mutable ConfigAndLanguageToBTStrings CompileDefinitionsCache; + mutable ConfigAndLanguageToBTStrings PrecompileHeadersCache; + mutable ConfigAndLanguageToBTStrings LinkOptionsCache; + mutable ConfigAndLanguageToBTStrings LinkDirectoriesCache; + +public: /** Get the include directories for this target. */ std::vector<BT<std::string>> GetIncludeDirectories( const std::string& config, const std::string& lang) const; |