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

Function free_one_node_pattern

src/cypher/cypher.c:1024–1033  ·  view source on GitHub ↗

Parse a single condition: var.prop OP value | var.prop IS [NOT] NULL | var.prop IN [...] */ Free the heap fields of a standalone node pattern (not owned by a pattern). */

Source from the content-addressed store, hash-verified

1022/* Parse a single condition: var.prop OP value | var.prop IS [NOT] NULL | var.prop IN [...] */
1023/* Free the heap fields of a standalone node pattern (not owned by a pattern). */
1024static void free_one_node_pattern(cbm_node_pattern_t *n) {
1025 safe_str_free(&n->variable);
1026 safe_str_free(&n->label);
1027 for (int j = 0; j < n->prop_count; j++) {
1028 safe_str_free(&n->props[j].key);
1029 safe_str_free(&n->props[j].value);
1030 }
1031 free(n->props);
1032 memset(n, 0, sizeof(*n));
1033}
1034
1035/* Free the heap fields of a standalone relationship pattern. */
1036static void free_one_rel_pattern(cbm_rel_pattern_t *r) {

Callers 1

parse_exists_predicateFunction · 0.85

Calls 1

safe_str_freeFunction · 0.85

Tested by

no test coverage detected