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

Function c_is_static

internal/cbm/doclink_c.c:577–591  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

575}
576
577static bool c_is_static(const char *src, TSNode decl) {
578 uint32_t nc = ts_node_named_child_count(decl);
579 for (uint32_t i = 0; i < nc; i++) {
580 TSNode c = ts_node_named_child(decl, i);
581 if (!c_kind(c, "storage_class_specifier")) {
582 continue;
583 }
584 uint32_t b = ts_node_start_byte(c);
585 uint32_t e = ts_node_end_byte(c);
586 if (e - b == CBM_SZ_6 && memcmp(src + b, "static", CBM_SZ_6) == 0) {
587 return true;
588 }
589 }
590 return false;
591}
592
593/* The names a static declaration or definition declares. */
594static void c_static_names(CBMExtractCtx *ctx, CBMHashTable *names, TSNode decl) {

Callers 1

c_static_namesFunction · 0.85

Calls 1

c_kindFunction · 0.85

Tested by

no test coverage detected