summaryrefslogtreecommitdiff
path: root/src/alloc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/alloc.c')
-rw-r--r--src/alloc.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/alloc.c b/src/alloc.c
index 40a3e235eab..3c622d05ff1 100644
--- a/src/alloc.c
+++ b/src/alloc.c
@@ -3174,6 +3174,13 @@ cleanup_vector (struct Lisp_Vector *vector)
ts_tree_delete(lisp_parser->tree);
ts_parser_delete(lisp_parser->parser);
}
+ else if (PSEUDOVECTOR_TYPEP (&vector->header, PVEC_TS_COMPILED_QUERY))
+ {
+ struct Lisp_TS_Query *lisp_query
+ = PSEUDOVEC_STRUCT (vector, Lisp_TS_Query);
+ ts_query_delete (lisp_query->query);
+ ts_query_cursor_delete (lisp_query->cursor);
+ }
#endif
#ifdef HAVE_MODULES
else if (PSEUDOVECTOR_TYPEP (&vector->header, PVEC_MODULE_FUNCTION))