diff options
author | Riley Bruins <ribru17@hotmail.com> | 2025-02-02 03:42:47 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-02-02 03:42:47 -0800 |
commit | 02ea0e77a19b116006dc04848703aaeed3f50ded (patch) | |
tree | 899e933b51f6831aabf763015cc1629cd87ec651 /src | |
parent | 48e3ac60c63341761b0f7e21262722f09127d374 (diff) | |
download | rneovim-02ea0e77a19b116006dc04848703aaeed3f50ded.tar.gz rneovim-02ea0e77a19b116006dc04848703aaeed3f50ded.tar.bz2 rneovim-02ea0e77a19b116006dc04848703aaeed3f50ded.zip |
refactor(treesitter): drop `LanguageTree._has_regions` #32274
This simplifies some logic in `languagetree.lua`, removing the need for
`_has_regions`, and removing side effects in `:included_regions()`.
Before:
- Edit is made which sets `_regions = nil`
- Upon the next call to `included_regions()` (usually right after we
marked `_regions` as `nil` due to an `_iter_regions()` call), if
`_regions` is nil, we repopulate the table (as long as the tree
actually has regions)
After:
- Edit is made which resets `_regions` if it exists
- `included_regions()` no longer needs to perform this logic itself, and
also no longer needs to read a `_has_regions` variable
Diffstat (limited to 'src')
0 files changed, 0 insertions, 0 deletions