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

Function ts_node_compare

src/mcp/test_impact_seed.c:137–147  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

135}
136
137static int ts_node_compare(const void *left, const void *right) {
138 const cbm_ti_node_t *a = left;
139 const cbm_ti_node_t *b = right;
140 if (a->start_line != b->start_line) {
141 return a->start_line < b->start_line ? -1 : 1;
142 }
143 if (a->end_line != b->end_line) {
144 return a->end_line < b->end_line ? -1 : 1;
145 }
146 return a->id < b->id ? -1 : (a->id > b->id ? 1 : 0);
147}
148
149static bool ts_node_from_row(cbm_ti_graph_t *g, cbm_ti_node_t *n, const cbm_node_t *row) {
150 n->id = row->id;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected