Rename stack_right_position -> stack_total_tree_size
I want to re-use the stack data structure for storing the re-usable nodes from the previous parse tree during an edit. In this case, the stack won't conceptually start at position zero, so the name 'right_position' doesn't make sense.
This commit is contained in:
parent
26f9e22193
commit
80b8a0a9fb
3 changed files with 4 additions and 4 deletions
|
|
@ -47,7 +47,7 @@ void ts_stack_shrink(TSStack *stack, size_t new_size) {
|
|||
stack->size = new_size;
|
||||
}
|
||||
|
||||
TSLength ts_stack_right_position(const TSStack *stack) {
|
||||
TSLength ts_stack_total_tree_size(const TSStack *stack) {
|
||||
TSLength result = ts_length_zero();
|
||||
for (size_t i = 0; i < stack->size; i++) {
|
||||
TSTree *node = stack->entries[i].node;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue