MCPcopy Create free account
hub / github.com/Kitware/CMake / Evaluate

Method Evaluate

Source/cmGeneratorExpressionNode.cxx:245–257  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

243 }
244
245 std::string Evaluate(std::vector<std::string> const& parameters,
246 cm::GenEx::Evaluation* eval,
247 GeneratorExpressionContent const* content,
248 cmGeneratorExpressionDAGChecker*) const override
249 {
250 if (parameters[0] != "1" && parameters[0] != "0") {
251 reportError(eval, content->GetOriginalExpression(),
252 "First parameter to $<IF> must resolve to exactly one '0' "
253 "or '1' value.");
254 return std::string();
255 }
256 return parameters[0] == "1" ? parameters[1] : parameters[2];
257 }
258} ifNode;
259
260static const struct StrEqualNode : public cmGeneratorExpressionNode

Callers 2

EvaluateMethod · 0.45

Calls 2

reportErrorFunction · 0.85
GetOriginalExpressionMethod · 0.80

Tested by

no test coverage detected