summaryrefslogtreecommitdiffstats
path: root/Source/cmake.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2020-03-27 11:49:29 (GMT)
committerKitware Robot <kwrobot@kitware.com>2020-03-27 11:50:28 (GMT)
commita6611577c33538af959348b49aec817dd9649c03 (patch)
tree788be17486c62f52ca6966fb6640a60592242aa3 /Source/cmake.cxx
parent7e3d81b1df9e2c192585d83300344546439e50bd (diff)
parentc84cf42897e4d95706d4f750c2ad085c84a259f2 (diff)
downloadCMake-a6611577c33538af959348b49aec817dd9649c03.zip
CMake-a6611577c33538af959348b49aec817dd9649c03.tar.gz
CMake-a6611577c33538af959348b49aec817dd9649c03.tar.bz2
Merge topic 'cmprop-getglobalprop'
c84cf42897 cmState::GetGlobalProperty: return cmProp Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !4521
Diffstat (limited to 'Source/cmake.cxx')
-rw-r--r--Source/cmake.cxx12
1 files changed, 6 insertions, 6 deletions
diff --git a/Source/cmake.cxx b/Source/cmake.cxx
index 0b7c4bc..2ec893f 100644
--- a/Source/cmake.cxx
+++ b/Source/cmake.cxx
@@ -1511,10 +1511,10 @@ int cmake::Configure()
this->Messenger->SetDevWarningsAsErrors(value && cmIsOff(*value));
int ret = this->ActualConfigure();
- const char* delCacheVars =
+ cmProp delCacheVars =
this->State->GetGlobalProperty("__CMAKE_DELETE_CACHE_CHANGE_VARS_");
- if (delCacheVars && delCacheVars[0] != 0) {
- return this->HandleDeleteCacheVariables(delCacheVars);
+ if (delCacheVars && !delCacheVars->empty()) {
+ return this->HandleDeleteCacheVariables(*delCacheVars);
}
return ret;
}
@@ -2430,7 +2430,7 @@ void cmake::AppendProperty(const std::string& prop, const std::string& value,
this->State->AppendGlobalProperty(prop, value, asString);
}
-const char* cmake::GetProperty(const std::string& prop)
+cmProp cmake::GetProperty(const std::string& prop)
{
return this->State->GetGlobalProperty(prop);
}
@@ -2671,10 +2671,10 @@ void cmake::IssueMessage(MessageType t, std::string const& text,
std::vector<std::string> cmake::GetDebugConfigs()
{
std::vector<std::string> configs;
- if (const char* config_list =
+ if (cmProp config_list =
this->State->GetGlobalProperty("DEBUG_CONFIGURATIONS")) {
// Expand the specified list and convert to upper-case.
- cmExpandList(config_list, configs);
+ cmExpandList(*config_list, configs);
std::transform(configs.begin(), configs.end(), configs.begin(),
cmSystemTools::UpperCase);
}