Update runtime files
diff --git a/runtime/doc/editing.txt b/runtime/doc/editing.txt
index 3493510..9736d4c 100644
--- a/runtime/doc/editing.txt
+++ b/runtime/doc/editing.txt
@@ -1,4 +1,4 @@
-*editing.txt* For Vim version 8.2. Last change: 2021 Oct 16
+*editing.txt* For Vim version 8.2. Last change: 2021 Dec 11
VIM REFERENCE MANUAL by Bram Moolenaar
diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt
index 21cf3f6..6765bdc 100644
--- a/runtime/doc/eval.txt
+++ b/runtime/doc/eval.txt
@@ -1,4 +1,4 @@
-*eval.txt* For Vim version 8.2. Last change: 2021 Nov 20
+*eval.txt* For Vim version 8.2. Last change: 2021 Dec 15
VIM REFERENCE MANUAL by Bram Moolenaar
diff --git a/runtime/doc/helphelp.txt b/runtime/doc/helphelp.txt
index 0fa5d8f..357a64e 100644
--- a/runtime/doc/helphelp.txt
+++ b/runtime/doc/helphelp.txt
@@ -1,4 +1,4 @@
-*helphelp.txt* For Vim version 8.2. Last change: 2021 Nov 18
+*helphelp.txt* For Vim version 8.2. Last change: 2021 Dec 13
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -163,7 +163,7 @@
The initial height of the help window can be set with the 'helpheight' option
(default 20).
-
+ *help-buffer-options*
When the help buffer is created, several local options are set to make sure
the help text is displayed as it was intended:
'iskeyword' nearly all ASCII chars except ' ', '*', '"' and '|'
diff --git a/runtime/doc/map.txt b/runtime/doc/map.txt
index 981ecf7..fc3f425 100644
--- a/runtime/doc/map.txt
+++ b/runtime/doc/map.txt
@@ -1,4 +1,4 @@
-*map.txt* For Vim version 8.2. Last change: 2021 Nov 20
+*map.txt* For Vim version 8.2. Last change: 2021 Dec 15
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -173,7 +173,7 @@
"<unique>" can be used in any order. They must appear right after the
command, before any other arguments.
- *:map-local* *:map-<buffer>* *E224* *E225*
+ *:map-local* *:map-<buffer>* *:map-buffer* *E224* *E225*
If the first argument to one of these commands is "<buffer>" the mapping will
be effective in the current buffer only. Example: >
:map <buffer> ,w /[.,;]<CR>
@@ -232,7 +232,7 @@
"<script>" overrules the command name. Using ":noremap <script>" is
preferred, because it's clearer that remapping is (mostly) disabled.
- *:map-<unique>* *E226* *E227*
+ *:map-<unique>* *:map-unique* *E226* *E227*
If the first argument to one of these commands is "<unique>" and it is used to
define a new mapping or abbreviation, the command will fail if the mapping or
abbreviation already exists. Example: >
@@ -974,28 +974,35 @@
" doubling <F4> works on a line
nnoremap <expr> <F4><F4> CountSpaces() .. '_'
- function CountSpaces(type = '') abort
+ function CountSpaces(virtualedit = '', irregular_block = v:false, type = '') abort
if a:type == ''
- set opfunc=CountSpaces
+ let &operatorfunc = function('CountSpaces', [&virtualedit, v:false])
+ set virtualedit=block
return 'g@'
- endif
+ endif
+ let cb_save = &clipboard
let sel_save = &selection
let reg_save = getreginfo('"')
- let cb_save = &clipboard
let visual_marks_save = [getpos("'<"), getpos("'>")]
try
- set clipboard= selection=inclusive
- let commands = #{line: "'[V']y", char: "`[v`]y", block: "`[\<c-v>`]y"}
- silent exe 'noautocmd keepjumps normal! ' .. get(commands, a:type, '')
- echom getreg('"')->count(' ')
+ set clipboard= selection=inclusive virtualedit=
+ let commands = #{line: "'[V']", char: "`[v`]", block: "`[\<C-V>`]"}->get(a:type, 'v')
+ if getpos("']")[-1] != 0 || a:irregular_block
+ let commands ..= 'oO$'
+ let &operatorfunc = function('CountSpaces', [a:virtualedit, v:true])
+ endif
+ let commands ..= 'y'
+ execute 'silent noautocmd keepjumps normal! ' .. commands
+ echomsg getreg('"')->count(' ')
finally
call setreg('"', reg_save)
call setpos("'<", visual_marks_save[0])
call setpos("'>", visual_marks_save[1])
let &clipboard = cb_save
let &selection = sel_save
+ let &virtualedit = a:virtualedit
endtry
endfunction
diff --git a/runtime/doc/message.txt b/runtime/doc/message.txt
index cbb320a..1690e41 100644
--- a/runtime/doc/message.txt
+++ b/runtime/doc/message.txt
@@ -1,4 +1,4 @@
-*message.txt* For Vim version 8.2. Last change: 2021 Jul 31
+*message.txt* For Vim version 8.2. Last change: 2021 Dec 13
VIM REFERENCE MANUAL by Bram Moolenaar
diff --git a/runtime/doc/motion.txt b/runtime/doc/motion.txt
index 81310a9..4412d56 100644
--- a/runtime/doc/motion.txt
+++ b/runtime/doc/motion.txt
@@ -1,4 +1,4 @@
-*motion.txt* For Vim version 8.2. Last change: 2021 Dec 04
+*motion.txt* For Vim version 8.2. Last change: 2021 Dec 13
VIM REFERENCE MANUAL by Bram Moolenaar
diff --git a/runtime/doc/tags b/runtime/doc/tags
index f694ba2..fc5a0c9 100644
--- a/runtime/doc/tags
+++ b/runtime/doc/tags
@@ -118,6 +118,8 @@
'cc' options.txt /*'cc'*
'ccv' options.txt /*'ccv'*
'cd' options.txt /*'cd'*
+'cdh' options.txt /*'cdh'*
+'cdhome' options.txt /*'cdhome'*
'cdpath' options.txt /*'cdpath'*
'cedit' options.txt /*'cedit'*
'cf' options.txt /*'cf'*
@@ -2754,6 +2756,7 @@
:map-<unique> map.txt /*:map-<unique>*
:map-alt-keys map.txt /*:map-alt-keys*
:map-arguments map.txt /*:map-arguments*
+:map-buffer map.txt /*:map-buffer*
:map-cmd map.txt /*:map-cmd*
:map-commands map.txt /*:map-commands*
:map-expression map.txt /*:map-expression*
@@ -2767,6 +2770,7 @@
:map-special-chars map.txt /*:map-special-chars*
:map-special-keys map.txt /*:map-special-keys*
:map-undo map.txt /*:map-undo*
+:map-unique map.txt /*:map-unique*
:map-verbose map.txt /*:map-verbose*
:map_l map.txt /*:map_l*
:map_l! map.txt /*:map_l!*
@@ -7270,6 +7274,7 @@
hebrew hebrew.txt /*hebrew*
hebrew.txt hebrew.txt /*hebrew.txt*
help helphelp.txt /*help*
+help-buffer-options helphelp.txt /*help-buffer-options*
help-context help.txt /*help-context*
help-curwin tips.txt /*help-curwin*
help-summary usr_02.txt /*help-summary*
diff --git a/runtime/doc/term.txt b/runtime/doc/term.txt
index 3333a3a..8862d0a 100644
--- a/runtime/doc/term.txt
+++ b/runtime/doc/term.txt
@@ -1,4 +1,4 @@
-*term.txt* For Vim version 8.2. Last change: 2021 Dec 04
+*term.txt* For Vim version 8.2. Last change: 2021 Dec 08
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -150,6 +150,8 @@
" Enable focus event tracking, see :help xterm-focus-event
let &t_fe = "\<Esc>[?1004h"
let &t_fd = "\<Esc>[?1004l"
+ execute "set <FocusGained>=\<Esc>[I"
+ execute "set <FocusLost>=\<Esc>[O"
" Enable modified arrow keys, see :help arrow_modifiers
execute "silent! set <xUp>=\<Esc>[@;*A"
@@ -606,6 +608,8 @@
you may have to set the options yourself: >
let &t_fe = "\<Esc>[?1004h"
let &t_fd = "\<Esc>[?1004l"
+ execute "set <FocusGained>=\<Esc>[I"
+ execute "set <FocusLost>=\<Esc>[O"
If this causes garbage to show when Vim starts up then it doesn't work.
*termcap-colors*
diff --git a/runtime/doc/testing.txt b/runtime/doc/testing.txt
index d064dc1..44296f0 100644
--- a/runtime/doc/testing.txt
+++ b/runtime/doc/testing.txt
@@ -1,4 +1,4 @@
-*testing.txt* For Vim version 8.2. Last change: 2021 Aug 15
+*testing.txt* For Vim version 8.2. Last change: 2021 Dec 11
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -65,7 +65,8 @@
Like garbagecollect(), but executed right away. This must
only be called directly to avoid any structure to exist
internally, and |v:testing| must have been set before calling
- any function.
+ any function. This will not work when called from a :def
+ function, because variables on the stack will be freed.
test_garbagecollect_soon() *test_garbagecollect_soon()*
diff --git a/runtime/doc/todo.txt b/runtime/doc/todo.txt
index 1772aa1..80ea2a3 100644
--- a/runtime/doc/todo.txt
+++ b/runtime/doc/todo.txt
@@ -1,4 +1,4 @@
-*todo.txt* For Vim version 8.2. Last change: 2021 Dec 05
+*todo.txt* For Vim version 8.2. Last change: 2021 Dec 15
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -39,7 +39,7 @@
-------------------- Known bugs and current work -----------------------
Vim9 - Make everything work:
-- Check TODO items in vim9compile.c and vim9execute.c
+- Check TODO items in vim9execute.c
- use CheckLegacyAndVim9Success(lines) in many more places
- For builtin functions using tv_get_string*() use check_for_string() to be
more strict about the argument type (not a bool).
@@ -194,8 +194,6 @@
- GUI: When using ":set go+=!" a system() call causes the hit-enter prompt.
(#3327)
- Allow for specifying the directory, with ++cwd={dir}.
-- With a vertical split only one window is updated. (Linwei, 2018 Jun 2,
- #2977)
- When pasting should call vterm_keyboard_start_paste(), e.g. when using
K_MIDDLEMOUSE, calling insert_reg().
- Users expect parsing the :term argument like a shell does, also support
@@ -271,6 +269,8 @@
Request to use "." for the cursor column in search pattern \%<.c and \%<.v.
(#8179)
+":filter set termcap" only filters terminal codes, not keys. (#9297)
+
Remove SPACE_IN_FILENAME ? It is only used for completion.
When 'term' starts with "foot" then default t_TI and t_TE to the values used
@@ -846,9 +846,7 @@
Win32 key codes are messy. Mike Williams tried to fix that, but now old
mappings no longer work. Create a new terminal for the better solution?
-Compiler warnings (geeknik, 2017 Oct 26):
-- signed integer overflow in do_sub() (#2249)
-- signed integer overflow in get_address() (#2248)
+Compiler warning (geeknik, 2017 Oct 26):
- undefined left shift in get_string_tv() (#2250)
Add Native language protocol server (LSP) support. (Yegappan Lakshmanan, 2018
@@ -3895,7 +3893,7 @@
$HOME/_vimrc, etc.) and add "edit vimrc" to the File menu.
- Add a way to save local settings and mappings into a new plugin file.
":mkplugin <file>"?
-- Add mappings local to a window: ":map <window> ..."?
+- Add mappings local to a window: ":map <window> ..." #9339
9 Add buffer-local menu. Should offer a choice between removing the menu or
disabling it. Be careful that tear-offs don't disappear (keep one empty
item?).
diff --git a/runtime/doc/various.txt b/runtime/doc/various.txt
index 6bccc83..b82427c 100644
--- a/runtime/doc/various.txt
+++ b/runtime/doc/various.txt
@@ -1,4 +1,4 @@
-*various.txt* For Vim version 8.2. Last change: 2021 Nov 30
+*various.txt* For Vim version 8.2. Last change: 2021 Dec 13
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -598,7 +598,7 @@
|:oldfiles| - filter by file name
|:registers| - filter by register contents
(does not work multi-line)
- |:set| - filter by variable name
+ |:set| - filter by option name
Only normal messages are filtered, error messages are
not.
diff --git a/runtime/doc/vim9.txt b/runtime/doc/vim9.txt
index 856ec2f..990d759 100644
--- a/runtime/doc/vim9.txt
+++ b/runtime/doc/vim9.txt
@@ -1,4 +1,4 @@
-*vim9.txt* For Vim version 8.2. Last change: 2021 Dec 01
+*vim9.txt* For Vim version 8.2. Last change: 2021 Dec 15
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -568,6 +568,20 @@
})
No command can follow the "{", only a comment can be used there.
+If the statements include a dictionary, its closing bracket must not be
+written at the start of a line. Otherwise, it would be parsed as the end of
+the block. This does not work: >
+ command NewCommand {
+ let g:mydict = {
+ 'key': 'value',
+ } # ERROR: will be recognized as the end of the block
+ }
+Put the '}' after the last item to avoid this: >
+ command NewCommand {
+ let g:mydict = {
+ 'key': 'value' }
+ }
+
Rationale: The "}" cannot be after a command because it would require parsing
the commands to find it. For consistency with that no command can follow the
"{". Unfortunately this means using "() => { command }" does not work, line