Simplify allocation-recording in test suite using new ts_set_allocator API
This commit is contained in:
parent
e01ea9ff51
commit
622359b400
19 changed files with 245 additions and 254 deletions
|
|
@ -722,7 +722,6 @@ void ts_stack_clear(Stack *self) {
|
|||
|
||||
bool ts_stack_print_dot_graph(Stack *self, const TSLanguage *language, FILE *f) {
|
||||
array_reserve(&self->iterators, 32);
|
||||
bool was_recording_allocations = ts_toggle_allocation_recording(false);
|
||||
if (!f) f = stderr;
|
||||
|
||||
fprintf(f, "digraph stack {\n");
|
||||
|
|
@ -851,7 +850,6 @@ bool ts_stack_print_dot_graph(Stack *self, const TSLanguage *language, FILE *f)
|
|||
fprintf(f, "}\n");
|
||||
|
||||
array_delete(&visited_nodes);
|
||||
ts_toggle_allocation_recording(was_recording_allocations);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue