diff options
| author | glepnir <glephunter@gmail.com> | 2026-03-13 18:13:58 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-03-13 06:13:58 -0400 |
| commit | 3f10bb87efad4070dfe03d2abcb3b4c6222597a5 (patch) | |
| tree | 07f2e10d968c23e48b6e9d1e4c1fdf449e0bde68 /runtime/lua/vim/provider/python.lua | |
| parent | f3ec657ebc02e8fb68e7cf46213333932325fe2f (diff) | |
| download | rneovim-3f10bb87efad4070dfe03d2abcb3b4c6222597a5.tar.gz rneovim-3f10bb87efad4070dfe03d2abcb3b4c6222597a5.tar.bz2 rneovim-3f10bb87efad4070dfe03d2abcb3b4c6222597a5.zip | |
fix(completion): wrong CompleteDone reason for auto-inserted sole match #38280
Problem: #38169 used compl_used_match to determine the CompleteDone
reason, but this fires too broadly, it also changes the reason to
"accept" when the popup was shown and the user dismissed it with <Esc>
or <Space>, breaking snippet completion with autocomplete.
Solution: Instead of checking compl_used_match in, check whether the pum
was never shown (compl_match_array == NULL) in ins_compl_stop().
When a match was inserted but the pum never displayed,
set the completed word so CompleteDone fires with reason "accept".
This keeps the "discard" reason intact when the user dismisses a visible
pum without confirming.
Diffstat (limited to 'runtime/lua/vim/provider/python.lua')
0 files changed, 0 insertions, 0 deletions