1
0
forked from aniani/vim

patch 8.2.4107: script context not restored after using <ScriptCmd>

Problem:    Script context not restored after using <ScriptCmd>.
Solution:   Also restore context when not in a script. (closes #9536)
            Add the 'c' flag to feedkeys() to be able to test this.
This commit is contained in:
Bram Moolenaar
2022-01-16 13:30:33 +00:00
parent fa1a457059
commit a9725221ac
5 changed files with 36 additions and 4 deletions

View File

@@ -2394,6 +2394,9 @@ feedkeys({string} [, {mode}]) *feedkeys()*
Note that if you manage to call feedkeys() while
executing commands, thus calling it recursively, then
all typeahead will be consumed by the last call.
'c' Remove any script context when executing, so that
legacy script syntax applies, "s:var" does not work,
etc.
'!' When used with 'x' will not end Insert mode. Can be
used in a test when a timer is set to exit Insert mode
a little later. Useful for testing CursorHoldI.