Skip to content

Commit

Permalink
Merge remote-tracking branch 'vim/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
ychin committed Sep 29, 2023
2 parents c83901a + f3b68d4 commit d41f345
Show file tree
Hide file tree
Showing 65 changed files with 6,223 additions and 2,993 deletions.
2 changes: 1 addition & 1 deletion .github/labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,6 @@ runtime:

termdebug: runtime/pack/dist/opt/termdebug/plugin/termdebug.vim

netrw:
plugin-netrw:
- any: ['runtime/plugin/netrwPlugin.vim']
- any: ['runtime/autoload/netrw*']
26 changes: 13 additions & 13 deletions runtime/doc/builtin.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6832,55 +6832,55 @@ printf({fmt}, {expr1} ...) *printf()*
echo printf("%1$*2$.*3$f", 1.4142135, 6, 2)
< 1.41

*E1400*
*E1500*
You cannot mix positional and non-positional arguments: >
echo printf("%s%1$s", "One", "Two")
< E1400: Cannot mix positional and non-positional
< E1500: Cannot mix positional and non-positional
arguments: %s%1$s

*E1401*
*E1501*
You cannot skip a positional argument in a format string: >
echo printf("%3$s%1$s", "One", "Two", "Three")
< E1401: format argument 2 unused in $-style
< E1501: format argument 2 unused in $-style
format: %3$s%1$s

*E1402*
*E1502*
You can re-use a [field-width] (or [precision]) argument: >
echo printf("%1$d at width %2$d is: %01$*2$d", 1, 2)
< 1 at width 2 is: 01

However, you can't use it as a different type: >
echo printf("%1$d at width %2$ld is: %01$*2$d", 1, 2)
< E1402: Positional argument 2 used as field
< E1502: Positional argument 2 used as field
width reused as different type: long int/int

*E1403*
*E1503*
When a positional argument is used, but not the correct number
or arguments is given, an error is raised: >
echo printf("%1$d at width %2$d is: %01$*2$.*3$d", 1, 2)
< E1403: Positional argument 3 out of bounds:
< E1503: Positional argument 3 out of bounds:
%1$d at width %2$d is: %01$*2$.*3$d

Only the first error is reported: >
echo printf("%01$*2$.*3$d %4$d", 1, 2)
< E1403: Positional argument 3 out of bounds:
< E1503: Positional argument 3 out of bounds:
%01$*2$.*3$d %4$d

*E1404*
*E1504*
A positional argument can be used more than once: >
echo printf("%1$s %2$s %1$s", "One", "Two")
< One Two One

However, you can't use a different type the second time: >
echo printf("%1$s %2$s %1$d", "One", "Two")
< E1404: Positional argument 1 type used
< E1504: Positional argument 1 type used
inconsistently: int/string

*E1405*
*E1505*
Various other errors that lead to a format string being
wrongly formatted lead to: >
echo printf("%1$d at width %2$d is: %01$*2$.3$d", 1, 2)
< E1405: Invalid format specifier:
< E1505: Invalid format specifier:
%1$d at width %2$d is: %01$*2$.3$d

prompt_getprompt({buf}) *prompt_getprompt()*
Expand Down
20 changes: 15 additions & 5 deletions runtime/doc/cmdline.txt
Original file line number Diff line number Diff line change
Expand Up @@ -517,16 +517,26 @@ example, to match only files that end in ".c": >
:e *.c$
This will not match a file ending in ".cpp". Without the "$" it does match.

The old value of an option can be obtained by hitting 'wildchar' just after
the '='. For example, typing 'wildchar' after ":set dir=" will insert the
current value of 'dir'. This overrules file name completion for the options
that take a file name.

If you would like using <S-Tab> for CTRL-P in an xterm, put this command in
your .cshrc: >
xmodmap -e "keysym Tab = Tab Find"
And this in your .vimrc: >
:cmap <Esc>[1~ <C-P>
< *complete-set-option*
When setting an option using |:set=|, the old value of an option can be
obtained by hitting 'wildchar' just after the '='. For example, typing
'wildchar' after ":set dir=" will insert the current value of 'dir'. This
overrules file name completion for the options that take a file name.

When using |:set=|, |:set+=|, or |:set^=|, string options that have
pre-defined names or syntax (e.g. 'diffopt', 'listchars') or are a list of
single-character flags (e.g. 'shortmess') will also present a list of possible
values for completion when using 'wildchar'.

When using |:set-=|, comma-separated options like 'diffopt' or 'backupdir'
will show each item separately. Flag list options like 'shortmess' will show
both the entire old value and the individual flags. Otherwise completion will
just fill in with the entire old value.

==============================================================================
3. Ex command-lines *cmdline-lines*
Expand Down
6 changes: 4 additions & 2 deletions runtime/doc/editing.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
*editing.txt* For Vim version 9.0. Last change: 2023 Apr 23
*editing.txt* For Vim version 9.0. Last change: 2023 Sep 22


VIM REFERENCE MANUAL by Bram Moolenaar
Expand Down Expand Up @@ -385,7 +385,9 @@ as a wildcard when "[" is in the 'isfname' option. A simple way to avoid this
is to use "path\[[]abc]", this matches the file "path\[abc]".

*starstar-wildcard*
Expanding "**" is possible on Unix, Win32, macOS and a few other systems.
Expanding "**" is possible on Unix, Win32, macOS and a few other systems (but
it may depend on your 'shell' setting. It's known to work correctly for zsh; for
bash this requires at least bash version >= 4.X).
This allows searching a directory tree. This goes up to 100 directories deep.
Note there are some commands where this works slightly differently, see
|file-searching|.
Expand Down
26 changes: 17 additions & 9 deletions runtime/doc/motion.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
*motion.txt* For Vim version 9.0. Last change: 2023 Sep 18
*motion.txt* For Vim version 9.0. Last change: 2023 Sep 28


VIM REFERENCE MANUAL by Bram Moolenaar
Expand Down Expand Up @@ -592,42 +592,48 @@ a] *v_a]* *v_a[* *a]* *a[*
a[ "a [] block", select [count] '[' ']' blocks. This
goes backwards to the [count] unclosed '[', and finds
the matching ']'. The enclosed text is selected,
including the '[' and ']'.
including the '[' and ']'. The |cpo-M| option flag
is used to handle escaped brackets.
When used in Visual mode it is made characterwise.

i] *v_i]* *v_i[* *i]* *i[*
i[ "inner [] block", select [count] '[' ']' blocks. This
goes backwards to the [count] unclosed '[', and finds
the matching ']'. The enclosed text is selected,
excluding the '[' and ']'.
excluding the '[' and ']'. The |cpo-M| option flag
is used to handle escaped brackets.
When used in Visual mode it is made characterwise.

a) *v_a)* *a)* *a(*
a( *vab* *v_ab* *v_a(* *ab*
ab "a block", select [count] blocks, from "[count] [(" to
the matching ')', including the '(' and ')' (see
|[(|). Does not include white space outside of the
parenthesis.
parenthesis. The |cpo-M| option flag is used to
handle escaped parenthesis.
When used in Visual mode it is made characterwise.

i) *v_i)* *i)* *i(*
i( *vib* *v_ib* *v_i(* *ib*
ib "inner block", select [count] blocks, from "[count] [("
to the matching ')', excluding the '(' and ')' (see
|[(|). If the cursor is not inside a () block, then
find the next "(".
find the next "(". The |cpo-M| option flag
is used to handle escaped parenthesis.
When used in Visual mode it is made characterwise.

a> *v_a>* *v_a<* *a>* *a<*
a< "a <> block", select [count] <> blocks, from the
[count]'th unmatched '<' backwards to the matching
'>', including the '<' and '>'.
'>', including the '<' and '>'. The |cpo-M| option flag
is used to handle escaped '<' and '>'.
When used in Visual mode it is made characterwise.

i> *v_i>* *v_i<* *i>* *i<*
i< "inner <> block", select [count] <> blocks, from
the [count]'th unmatched '<' backwards to the matching
'>', excluding the '<' and '>'.
'>', excluding the '<' and '>'. The |cpo-M| option flag
is used to handle escaped '<' and '>'.
When used in Visual mode it is made characterwise.

*v_at* *at*
Expand All @@ -649,14 +655,16 @@ a} *v_a}* *a}* *a{*
a{ *v_aB* *v_a{* *aB*
aB "a Block", select [count] Blocks, from "[count] [{" to
the matching '}', including the '{' and '}' (see
|[{|).
|[{|). The |cpo-M| option flag is used to handle
escaped braces.
When used in Visual mode it is made characterwise.

i} *v_i}* *i}* *i{*
i{ *v_iB* *v_i{* *iB*
iB "inner Block", select [count] Blocks, from "[count] [{"
to the matching '}', excluding the '{' and '}' (see
|[{|).
|[{|). The |cpo-M| option flag is used to handle
escaped braces.
When used in Visual mode it is made characterwise.

a" *v_aquote* *aquote*
Expand Down
15 changes: 10 additions & 5 deletions runtime/doc/options.txt
Original file line number Diff line number Diff line change
Expand Up @@ -71,15 +71,17 @@ achieve special effects. These options come in three forms:
'ttytype'
Warning: This may have a lot of side effects.

*:set-args* *E487* *E521*
*:set-args* *:set=* *E487* *E521*
:se[t] {option}={value} or
:se[t] {option}:{value}
Set string or number option to {value}.
For numeric options the value can be given in decimal,
hex (preceded with 0x) or octal (preceded with '0').
The old value can be inserted by typing 'wildchar' (by
default this is a <Tab> or CTRL-E if 'compatible' is
set). See |cmdline-completion|.
set). Many string options with fixed syntax and names
also support completing known values. See
|cmdline-completion| and |complete-set-option|.
White space between {option} and '=' is allowed and
will be ignored. White space between '=' and {value}
is not allowed.
Expand Down Expand Up @@ -113,6 +115,9 @@ achieve special effects. These options come in three forms:
When the option is a list of flags, {value} must be
exactly as they appear in the option. Remove flags
one by one to avoid problems.
The individual values from a comma separated list or
list of flags can be inserted by typing 'wildchar'.
See |complete-set-option|.
Also see |:set-args| above.

The {option} arguments to ":set" may be repeated. For example: >
Expand Down Expand Up @@ -6886,9 +6891,9 @@ A jump table for the options with a short description can be found at |Q_op|.
*'scrollbind'* *'scb'* *'noscrollbind'* *'noscb'*
'scrollbind' 'scb' boolean (default off)
local to window
See also |scroll-binding|. When this option is set, the current
window scrolls as other scrollbind windows (windows that also have
this option set) scroll. This option is useful for viewing the
See also |scroll-binding|. When this option is set, scrolling the
current window also scrolls other scrollbind windows (windows that
also have this option set). This option is useful for viewing the
differences between two versions of a file, see 'diff'.
See |'scrollopt'| for options that determine how this option should be
interpreted.
Expand Down
15 changes: 8 additions & 7 deletions runtime/doc/scroll.txt
Original file line number Diff line number Diff line change
Expand Up @@ -191,16 +191,16 @@ windows can be given this behavior by setting the (window-specific)
other 'scrollbind' windows are scrolled the same amount, if possible. The
behavior of 'scrollbind' can be modified by the 'scrollopt' option.

When using the scrollbars, the binding only happens when scrolling the window
with focus (where the cursor is). You can use this to avoid scroll-binding
for a moment without resetting options.
When using the scrollbars or the mouse wheel, the binding only happens when
scrolling the window with focus (where the cursor is). You can use this to
avoid scroll-binding for a moment without resetting options.

When a window also has the 'diff' option set, the scroll-binding uses the
differences between the two buffers to synchronize the position precisely.
Otherwise the following method is used.

*scrollbind-relative*
Each 'scrollbind' window keeps track of its "relative offset," which can be
Each 'scrollbind' window keeps track of its "relative offset", which can be
thought of as the difference between the current window's vertical scroll
position and the other window's vertical scroll position. When one of the
'scrollbind' windows is asked to vertically scroll past the beginning or end
Expand All @@ -224,9 +224,10 @@ option.

*scrollbind-quickadj*
The 'scrollbind' flag is meaningful when using keyboard commands to vertically
scroll a window, and also meaningful when using the vertical scrollbar of the
window which has the cursor focus. However, when using the vertical scrollbar
of a window which doesn't have the cursor focus, 'scrollbind' is ignored.
scroll a window, and is also meaningful when using the vertical scrollbar or
the mouse wheel in the window which has the cursor focus. However, when using
the vertical scrollbar or the mouse wheel in a window which doesn't have the
cursor focus, 'scrollbind' is ignored.
This allows quick adjustment of the relative offset of 'scrollbind' windows.

==============================================================================
Expand Down
26 changes: 20 additions & 6 deletions runtime/doc/tags
Original file line number Diff line number Diff line change
Expand Up @@ -3235,6 +3235,7 @@ $quote eval.txt /*$quote*
:set-inv options.txt /*:set-inv*
:set-termcap options.txt /*:set-termcap*
:set-verbose options.txt /*:set-verbose*
:set= options.txt /*:set=*
:set^= options.txt /*:set^=*
:set_env options.txt /*:set_env*
:setf options.txt /*:setf*
Expand Down Expand Up @@ -4533,14 +4534,15 @@ E1380 vim9class.txt /*E1380*
E1381 vim9class.txt /*E1381*
E1382 vim9class.txt /*E1382*
E1383 vim9class.txt /*E1383*
E1384 vim9class.txt /*E1384*
E1385 vim9class.txt /*E1385*
E1386 vim9class.txt /*E1386*
E1387 vim9class.txt /*E1387*
E1388 vim9class.txt /*E1388*
E1389 vim9class.txt /*E1389*
E139 message.txt /*E139*
E1390 vim9class.txt /*E1390*
E140 message.txt /*E140*
E1400 builtin.txt /*E1400*
E1401 builtin.txt /*E1401*
E1402 builtin.txt /*E1402*
E1403 builtin.txt /*E1403*
E1404 builtin.txt /*E1404*
E1405 builtin.txt /*E1405*
E141 message.txt /*E141*
E142 message.txt /*E142*
E143 autocmd.txt /*E143*
Expand All @@ -4552,6 +4554,12 @@ E148 repeat.txt /*E148*
E149 helphelp.txt /*E149*
E15 eval.txt /*E15*
E150 helphelp.txt /*E150*
E1500 builtin.txt /*E1500*
E1501 builtin.txt /*E1501*
E1502 builtin.txt /*E1502*
E1503 builtin.txt /*E1503*
E1504 builtin.txt /*E1504*
E1505 builtin.txt /*E1505*
E151 helphelp.txt /*E151*
E152 helphelp.txt /*E152*
E153 helphelp.txt /*E153*
Expand Down Expand Up @@ -6575,6 +6583,7 @@ complete-items insert.txt /*complete-items*
complete-popup insert.txt /*complete-popup*
complete-popuphidden insert.txt /*complete-popuphidden*
complete-script-local-functions cmdline.txt /*complete-script-local-functions*
complete-set-option cmdline.txt /*complete-set-option*
complete_CTRL-E insert.txt /*complete_CTRL-E*
complete_CTRL-Y insert.txt /*complete_CTRL-Y*
complete_add() builtin.txt /*complete_add()*
Expand All @@ -6590,6 +6599,7 @@ conceal syntax.txt /*conceal*
confirm() builtin.txt /*confirm()*
connection-refused message.txt /*connection-refused*
console-menus gui.txt /*console-menus*
constructor vim9class.txt /*constructor*
context.vim ft_context.txt /*context.vim*
control intro.txt /*control*
conversion-server mbyte.txt /*conversion-server*
Expand Down Expand Up @@ -6763,6 +6773,7 @@ debugger.txt debugger.txt /*debugger.txt*
dec-mouse options.txt /*dec-mouse*
decada_members ft_ada.txt /*decada_members*
deepcopy() builtin.txt /*deepcopy()*
default-constructor vim9class.txt /*default-constructor*
defaults.vim starting.txt /*defaults.vim*
defaults.vim-explained usr_05.txt /*defaults.vim-explained*
define-function userfunc.txt /*define-function*
Expand Down Expand Up @@ -9078,6 +9089,7 @@ netrw.vim pi_netrw.txt /*netrw.vim*
netrw_filehandler pi_netrw.txt /*netrw_filehandler*
netterm-mouse options.txt /*netterm-mouse*
network pi_netrw.txt /*network*
new() vim9class.txt /*new()*
new-5 version5.txt /*new-5*
new-6 version6.txt /*new-6*
new-7 version7.txt /*new-7*
Expand Down Expand Up @@ -9471,6 +9483,8 @@ printf-s builtin.txt /*printf-s*
printf-x builtin.txt /*printf-x*
printing print.txt /*printing*
printing-formfeed print.txt /*printing-formfeed*
private-method vim9class.txt /*private-method*
private-variable vim9class.txt /*private-variable*
profile repeat.txt /*profile*
profiling repeat.txt /*profiling*
profiling-variable eval.txt /*profiling-variable*
Expand Down
Loading

0 comments on commit d41f345

Please sign in to comment.