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

Function unit_key

src/pipeline/doc_links_cs.c:4829–4834  ·  view source on GitHub ↗

The key of one unit step: everything it reads. false when it does not fit. */

Source from the content-addressed store, hash-verified

4827
4828/* The key of one unit step: everything it reads. false when it does not fit. */
4829static bool unit_key(char *buf, size_t cap, const cs_ctx_t *c, const cs_query_t *q) {
4830 int n = snprintf(buf, cap, "%d|%d|%d|%d|%d%d%d%c|%s", c->unit, c->group, (int)c->prod, q->arity,
4831 (int)q->types_only, (int)q->statics, (int)q->ctors, q->kind ? q->kind : '-',
4832 q->name);
4833 return n > 0 && (size_t)n < cap;
4834}
4835
4836/* The step under `key` (the caller holds the memo's lock); a new one is
4837 * added with its lock held, and *mine set: the caller finds its list. NULL

Callers 1

unit_usingsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected