aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/_meta/api.lua
diff options
context:
space:
mode:
authorL Lllvvuu <git@llllvvuu.dev>2023-09-11 23:15:24 -0700
committerChristian Clason <c.clason@uni-graz.at>2023-09-12 09:12:53 +0200
commit6b5f44817e93c2985f3ea32122f1dc0047054018 (patch)
tree235d42bdd5251ba4cddd11b46fa0262e9fa25c27 /runtime/lua/vim/_meta/api.lua
parent3849cc9c18f877751c2a72fb82887ab7f88e0ffa (diff)
downloadrneovim-6b5f44817e93c2985f3ea32122f1dc0047054018.tar.gz
rneovim-6b5f44817e93c2985f3ea32122f1dc0047054018.tar.bz2
rneovim-6b5f44817e93c2985f3ea32122f1dc0047054018.zip
fix(languagetree): remove double recursion in LanguageTree:parse
`LanguageTree:parse` is recursive, and calls `LanguageTree:for_each_child`, which is also recursive. That means that, starting from the third level (child of child of root), nodes will be parsed twice. Which then means that if the tree is N layers deep, there will be ~2^N parses even if the branching factor is 1. Now, why was the tree deepening with each character inserted? And why did this only regress in #24647? These are mysteries for another time. Fixes: #25104
Diffstat (limited to 'runtime/lua/vim/_meta/api.lua')
0 files changed, 0 insertions, 0 deletions