diff options
| author | zeertzjq <zeertzjq@outlook.com> | 2026-09-26 09:12:32 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-09-26 01:12:32 +0000 |
| commit | 683b2ce3be497320f4798fb9cadad073cf67aa0f (patch) | |
| tree | acd690c8ab3a66e120a3232f61d524f814f21213 /runtime/lua/vim/provider/python.lua | |
| parent | 48bba43ace33998795c31772b1843f4bea36d391 (diff) | |
| download | rneovim-683b2ce3be497320f4798fb9cadad073cf67aa0f.tar.gz rneovim-683b2ce3be497320f4798fb9cadad073cf67aa0f.tar.bz2 rneovim-683b2ce3be497320f4798fb9cadad073cf67aa0f.zip | |
vim-patch:9.2.1131: matching character ranges is slow with the bt re-engine (#42101)
Problem: The backtracking regexp engine expands the collections into a
character set that is tested one character at a time,
even though the NFA engine already recognizes them as the
faster \<type> classes.
Solution: Share the collection-parsing code between the two engines and
emit the corresponding class atom in the bt engine too.
These ranges are all unaffected by 'ignorecase' (which applies at
execution time): the digit and octal classes have no case, and the hex,
word, head and alpha classes already contain both cases, so the emitted
atom matches the collection identically. Only the bare LOWER ([a-z]) and
UPPER ([A-Z]) ranges and their negations are left out, because the old
engine has no case-insensitive opcode for them. Add tests for the
conversions.
closes: vim/vim#21340
https://github.com/vim/vim/commit/33402ca930f611c7ad28c9bb11e16f7aee52b09e
Co-authored-by: Julien Voisin <julien.voisin@dustri.org>
Diffstat (limited to 'runtime/lua/vim/provider/python.lua')
0 files changed, 0 insertions, 0 deletions