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

Function EnvironmentHelper

Source/cmCMakePresetsGraphReadJSON.cxx:238–251  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

236}
237
238bool EnvironmentHelper(cm::optional<std::string>& out,
239 Json::Value const* value, cmJSONState* state)
240{
241 if (!value || value->isNull()) {
242 out = cm::nullopt;
243 return true;
244 }
245 if (value->isString()) {
246 out = value->asString();
247 return true;
248 }
249 cmCMakePresetsErrors::INVALID_PRESET(value, state);
250 return false;
251}
252
253auto const VersionIntHelper =
254 JSONHelperBuilder::Int(cmCMakePresetsErrors::INVALID_VERSION);

Callers

nothing calls this directly

Calls 4

INVALID_PRESETFunction · 0.85
isNullMethod · 0.80
isStringMethod · 0.80
asStringMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…