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

Function cs_tmp_alloc

internal/cbm/doclink_cs.c:1035–1042  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1033}
1034
1035static void *cs_tmp_alloc(cs_scan_t *s, size_t n) {
1036 s->cost_bytes += n;
1037 void *p = cbm_arena_alloc(s->tmp, n ? n : SKIP_ONE);
1038 if (!p) {
1039 s->failed = true;
1040 }
1041 return p;
1042}
1043
1044/* Copy of source bytes [a, b) without whitespace and '@'. NULL unless it is a
1045 * (dotted) identifier of sane length and well-formed UTF-8: an error-recovered

Callers 10

cs_ident_dupFunction · 0.85
cs_brace_pushFunction · 0.85
cs_open_pushFunction · 0.85
cs_lex_keywordFunction · 0.85
cs_namespace_name_dupFunction · 0.85
cs_text_tparamsFunction · 0.85
cs_item_newFunction · 0.85
cs_walk_pushFunction · 0.85
cs_add_text_itemsFunction · 0.85
cs_emit_itemsFunction · 0.85

Calls 1

cbm_arena_allocFunction · 0.70

Tested by

no test coverage detected