MCPcopy Create free account
hub / github.com/chigraph/chigraph / nodeTypeFromName

Method nodeTypeFromName

libchigraph/src/LangModule.cpp:859–873  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

857}
858
859Result LangModule::nodeTypeFromName(boost::string_view name, const nlohmann::json& jsonData,
860 std::unique_ptr<NodeType>* toFill) {
861 Result res;
862
863 auto iter = nodes.find(name.to_string());
864 if (iter != nodes.end()) {
865 *toFill = iter->second(jsonData, res);
866 return res;
867 }
868
869 res.addEntry("E37", "Failed to find node in module",
870 {{"Module", "lang"}, {"Requested Node Type", name.to_string()}});
871
872 return res;
873}
874
875LangModule::~LangModule() {
876#if LLVM_VERSION_LESS_EQUAL(3, 6)

Callers 6

renameLocalVariableMethod · 0.45
retypeLocalVariableMethod · 0.45
setNameMethod · 0.45
updateNodeReferencesMethod · 0.45
nodeTypeFromModuleMethod · 0.45

Calls 3

to_stringMethod · 0.80
endMethod · 0.80
addEntryMethod · 0.80

Tested by

no test coverage detected