MCPcopy Create free account
hub / github.com/OpenMC2/OpenMC2 / set_default

Function set_default

src/Config.cpp:133–135  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

131
132template<class T>
133static void set_default(config_tree &tree, bool &modified, const config_tree::key_type &key, T value) {
134 if (!tree.get_child_optional(key)) tree.put(key, value), modified = true;
135}
136
137static bool set_defaults(config_tree &tree) {
138 bool modified = false;

Callers 1

set_defaultsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected