MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / reg_func

Function reg_func

internal/cbm/lsp/generated/cpp_stdlib_data.c:54–64  ·  view source on GitHub ↗

Helper: register a free function

Source from the content-addressed store, hash-verified

52
53// Helper: register a free function
54static void reg_func(CBMTypeRegistry* reg, CBMArena* arena,
55 const char* qn, const char* short_name, const CBMType* ret_type) {
56 CBMRegisteredFunc rf;
57 memset(&rf, 0, sizeof(rf));
58 rf.min_params = -1;
59 rf.qualified_name = qn;
60 rf.short_name = short_name;
61 rf.signature = cbm_type_func(arena, NULL, NULL,
62 ret_type ? (const CBMType*[]){ret_type, NULL} : NULL);
63 cbm_registry_add_func(reg, rf);
64}
65
66void cbm_cpp_stdlib_register(CBMTypeRegistry* reg, CBMArena* arena) {
67 const CBMType* t_void = cbm_type_builtin(arena, "void");

Callers 1

cbm_cpp_stdlib_registerFunction · 0.85

Calls 2

cbm_type_funcFunction · 0.85
cbm_registry_add_funcFunction · 0.85

Tested by

no test coverage detected