summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVitaly Stakhovsky <vvs31415@gitlab.org>2020-07-11 15:41:19 (GMT)
committerVitaly Stakhovsky <vvs31415@gitlab.org>2020-07-11 15:51:22 (GMT)
commit43f7b17816e2de899dc5e9d0ed650c615e455eb3 (patch)
tree150d59825de030e091baafa0b8f74f0d24798867
parentfd1df4995b6c1e063bb978e034a264b0e2d59f63 (diff)
downloadCMake-43f7b17816e2de899dc5e9d0ed650c615e455eb3.zip
CMake-43f7b17816e2de899dc5e9d0ed650c615e455eb3.tar.gz
CMake-43f7b17816e2de899dc5e9d0ed650c615e455eb3.tar.bz2
cmGeneratorExpressionInterpreter::Evaluate: remove const char* overload
-rw-r--r--Source/cmGeneratorExpression.cxx6
-rw-r--r--Source/cmGeneratorExpression.h2
-rw-r--r--Source/cmGeneratorTarget.cxx8
3 files changed, 3 insertions, 13 deletions
diff --git a/Source/cmGeneratorExpression.cxx b/Source/cmGeneratorExpression.cxx
index 6e293d5..840f511 100644
--- a/Source/cmGeneratorExpression.cxx
+++ b/Source/cmGeneratorExpression.cxx
@@ -406,9 +406,3 @@ const std::string& cmGeneratorExpressionInterpreter::Evaluate(
this->LocalGenerator, this->Config, this->HeadTarget, &dagChecker, nullptr,
this->Language);
}
-
-const std::string& cmGeneratorExpressionInterpreter::Evaluate(
- const char* expression, const std::string& property)
-{
- return this->Evaluate(std::string(expression ? expression : ""), property);
-}
diff --git a/Source/cmGeneratorExpression.h b/Source/cmGeneratorExpression.h
index 75bba02..09d8b88 100644
--- a/Source/cmGeneratorExpression.h
+++ b/Source/cmGeneratorExpression.h
@@ -199,8 +199,6 @@ public:
const std::string& Evaluate(std::string expression,
const std::string& property);
- const std::string& Evaluate(const char* expression,
- const std::string& property);
protected:
cmGeneratorExpression GeneratorExpression;
diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx
index ccd8e7e..b202e91 100644
--- a/Source/cmGeneratorTarget.cxx
+++ b/Source/cmGeneratorTarget.cxx
@@ -5411,8 +5411,7 @@ bool getTypedProperty<bool>(cmGeneratorTarget const* tgt,
}
cmProp value = tgt->GetProperty(prop);
- return cmIsOn(
- genexInterpreter->Evaluate(value ? value->c_str() : nullptr, prop));
+ return cmIsOn(genexInterpreter->Evaluate(value ? *value : "", prop));
}
template <>
@@ -5426,8 +5425,7 @@ const char* getTypedProperty<const char*>(
return value ? value->c_str() : nullptr;
}
- return genexInterpreter->Evaluate(value ? value->c_str() : nullptr, prop)
- .c_str();
+ return genexInterpreter->Evaluate(value ? *value : "", prop).c_str();
}
template <>
@@ -5441,7 +5439,7 @@ std::string getTypedProperty<std::string>(
return valueAsString(value ? value->c_str() : nullptr);
}
- return genexInterpreter->Evaluate(value ? value->c_str() : nullptr, prop);
+ return genexInterpreter->Evaluate(value ? *value : "", prop);
}
template <typename PropertyType>