Skip to content

Commit c981dc1

Browse files
committed
Merge remote-tracking branch 'vim/master'
2 parents 8bc8f4a + e366ed4 commit c981dc1

73 files changed

Lines changed: 1160 additions & 804 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/CODEOWNERS_vim

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ runtime/compiler/fbc.vim @dkearns
5353
runtime/compiler/gawk.vim @dkearns
5454
runtime/compiler/gjs.vim @dkearns
5555
runtime/compiler/haml.vim @tpope
56+
runtime/compiler/icon.vim @dkearns
5657
runtime/compiler/javac.vim @dkearns
5758
runtime/compiler/jest.vim @dkearns
5859
runtime/compiler/jjs.vim @dkearns
@@ -114,6 +115,7 @@ runtime/ftplugin/gprof.vim @dpelle
114115
runtime/ftplugin/haml.vim @tpope
115116
runtime/ftplugin/hgcommit.vim @k-takata
116117
runtime/ftplugin/i3config.vim @hiqua
118+
runtime/ftplugin/icon.vim @dkearns
117119
runtime/ftplugin/indent.vim @dkearns
118120
runtime/ftplugin/javascript.vim @dkearns
119121
runtime/ftplugin/javascriptreact.vim @dkearns
@@ -250,6 +252,7 @@ runtime/syntax/haml.vim @tpope
250252
runtime/syntax/haskell.vim @coot
251253
runtime/syntax/hgcommit.vim @k-takata
252254
runtime/syntax/i3config.vim @hiqua
255+
runtime/syntax/icon.vim @dkearns
253256
runtime/syntax/indent.vim @dkearns
254257
runtime/syntax/kconfig.vim @chrisbra
255258
runtime/syntax/less.vim @genoma

runtime/compiler/icon.vim

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
" Vim compiler file
2+
" Compiler: Icon Compiler
3+
" Maintainer: Doug Kearns <[email protected]>
4+
" Last Change: 2022 Jun 16
5+
6+
if exists("current_compiler")
7+
finish
8+
endif
9+
let current_compiler = "icont"
10+
11+
if exists(":CompilerSet") != 2 " older Vim always used :setlocal
12+
command -nargs=* CompilerSet setlocal <args>
13+
endif
14+
15+
let s:cpo_save = &cpo
16+
set cpo&vim
17+
18+
CompilerSet makeprg=icont\ -s
19+
CompilerSet errorformat=%-G%\\d%\\+\ errors%\\=,
20+
\%ERun-time\ error\ %n,
21+
\%ERun-time\ error\ %n\ in\ %m,
22+
\%ZTraceback:,
23+
\%+Coffending\ value:\ %.%#,
24+
\%CFile\ %f;\ Line\ %l,
25+
\%EFile\ %f;\ Line\ %l\ #\ %m,
26+
\%EFile\ %f;\ %m,
27+
\%E%f:%l:\ #\ %m,
28+
\%E%f:\ %m,
29+
\%+C%.%#,
30+
\%-G%.%#
31+
32+
let &cpo = s:cpo_save
33+
unlet s:cpo_save

runtime/doc/builtin.txt

Lines changed: 46 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*builtin.txt* For Vim version 8.2. Last change: 2022 Jun 05
1+
*builtin.txt* For Vim version 8.2. Last change: 2022 Jun 16
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -5899,6 +5899,8 @@ matchfuzzy({list}, {str} [, {dict}]) *matchfuzzy()*
58995899
matchseq When this item is present return only matches
59005900
that contain the characters in {str} in the
59015901
given sequence.
5902+
limit Maximum number of matches in {list} to be
5903+
returned. Zero means no limit.
59025904

59035905
If {list} is a list of dictionaries, then the optional {dict}
59045906
argument supports the following additional items:
@@ -5910,8 +5912,6 @@ matchfuzzy({list}, {str} [, {dict}]) *matchfuzzy()*
59105912
This should accept a dictionary item as the
59115913
argument and return the text for that item to
59125914
use for fuzzy matching.
5913-
limit Maximum number of matches in {list} to be
5914-
returned. Zero means no limit.
59155915

59165916
{str} is treated as a literal string and regular expression
59175917
matching is NOT supported. The maximum supported {str} length
@@ -8809,6 +8809,8 @@ strcharpart({src}, {start} [, {len} [, {skipcc}]]) *strcharpart()*
88098809
strcharpart('abc', -1, 2)
88108810
< results in 'a'.
88118811

8812+
Returns an empty string on error.
8813+
88128814
Can also be used as a |method|: >
88138815
GetText()->strcharpart(5)
88148816
@@ -8821,6 +8823,8 @@ strchars({string} [, {skipcc}]) *strchars()*
88218823
When {skipcc} set to 1, Composing characters are ignored.
88228824
|strcharlen()| always does this.
88238825

8826+
Returns zero on error.
8827+
88248828
Also see |strlen()|, |strdisplaywidth()| and |strwidth()|.
88258829

88268830
{skipcc} is only available after 7.4.755. For backward
@@ -8853,6 +8857,7 @@ strdisplaywidth({string} [, {col}]) *strdisplaywidth()*
88538857
'tabstop' and 'display'.
88548858
When {string} contains characters with East Asian Width Class
88558859
Ambiguous, this function's return value depends on 'ambiwidth'.
8860+
Returns zero on error.
88568861
Also see |strlen()|, |strwidth()| and |strchars()|.
88578862

88588863
Can also be used as a |method|: >
@@ -8886,6 +8891,7 @@ strgetchar({str}, {index}) *strgetchar()*
88868891
index. Composing characters are considered separate
88878892
characters here. Use |nr2char()| to convert the Number to a
88888893
String.
8894+
Returns -1 if {index} is invalid.
88898895
Also see |strcharpart()| and |strchars()|.
88908896

88918897
Can also be used as a |method|: >
@@ -8940,7 +8946,7 @@ strlen({string}) *strlen()*
89408946
The result is a Number, which is the length of the String
89418947
{string} in bytes.
89428948
If the argument is a Number it is first converted to a String.
8943-
For other types an error is given.
8949+
For other types an error is given and zero is returned.
89448950
If you want to count the number of multibyte characters use
89458951
|strchars()|.
89468952
Also see |len()|, |strdisplaywidth()| and |strwidth()|.
@@ -8971,6 +8977,8 @@ strpart({src}, {start} [, {len} [, {chars}]]) *strpart()*
89718977
example, to get the character under the cursor: >
89728978
strpart(getline("."), col(".") - 1, 1, v:true)
89738979
<
8980+
Returns an empty string on error.
8981+
89748982
Can also be used as a |method|: >
89758983
GetText()->strpart(5)
89768984
@@ -9033,6 +9041,8 @@ strtrans({string}) *strtrans()*
90339041
< This displays a newline in register a as "^@" instead of
90349042
starting a new line.
90359043

9044+
Returns an empty string on error.
9045+
90369046
Can also be used as a |method|: >
90379047
GetString()->strtrans()
90389048
@@ -9042,6 +9052,7 @@ strwidth({string}) *strwidth()*
90429052
cell, alternatively use |strdisplaywidth()|.
90439053
When {string} contains characters with East Asian Width Class
90449054
Ambiguous, this function's return value depends on 'ambiwidth'.
9055+
Returns zero on error.
90459056
Also see |strlen()|, |strdisplaywidth()| and |strchars()|.
90469057

90479058
Can also be used as a |method|: >
@@ -9067,6 +9078,8 @@ submatch({nr} [, {list}]) *submatch()* *E935*
90679078
When substitute() is used recursively only the submatches in
90689079
the current (deepest) call can be obtained.
90699080

9081+
Returns an empty string or list on error.
9082+
90709083
Examples: >
90719084
:s/\d\+/\=submatch(0) + 1/
90729085
:echo substitute(text, '\d\+', '\=submatch(0) + 1', '')
@@ -9117,7 +9130,9 @@ substitute({string}, {pat}, {sub}, {flags}) *substitute()*
91179130
|submatch()| returns. Example: >
91189131
:echo substitute(s, '%\(\x\x\)', {m -> '0x' .. m[1]}, 'g')
91199132
9120-
< Can also be used as a |method|: >
9133+
< Returns an empty string on error.
9134+
9135+
Can also be used as a |method|: >
91219136
GetString()->substitute(pat, sub, flags)
91229137
91239138
swapinfo({fname}) *swapinfo()*
@@ -9172,6 +9187,8 @@ synID({lnum}, {col}, {trans}) *synID()*
91729187
Warning: This function can be very slow. Best speed is
91739188
obtained by going through the file in forward direction.
91749189

9190+
Returns zero on error.
9191+
91759192
Example (echoes the name of the syntax item under the cursor): >
91769193
:echo synIDattr(synID(line("."), col("."), 1), "name")
91779194
<
@@ -9209,6 +9226,8 @@ synIDattr({synID}, {what} [, {mode}]) *synIDattr()*
92099226
"undercurl" "1" if undercurled
92109227
"strike" "1" if strikethrough
92119228

9229+
Returns an empty string on error.
9230+
92129231
Example (echoes the color of the syntax item under the
92139232
cursor): >
92149233
:echo synIDattr(synIDtrans(synID(line("."), col("."), 1)), "fg")
@@ -9223,6 +9242,8 @@ synIDtrans({synID}) *synIDtrans()*
92239242
highlight the character. Highlight links given with
92249243
":highlight link" are followed.
92259244

9245+
Returns zero on error.
9246+
92269247
Can also be used as a |method|: >
92279248
:echo synID(line("."), col("."), 1)->synIDtrans()->synIDattr("fg")
92289249
@@ -9267,7 +9288,7 @@ synstack({lnum}, {col}) *synstack()*
92679288
echo synIDattr(id, "name")
92689289
endfor
92699290
< When the position specified with {lnum} and {col} is invalid
9270-
nothing is returned. The position just after the last
9291+
an empty List is returned. The position just after the last
92719292
character in a line and the first column in an empty line are
92729293
valid positions.
92739294

@@ -9381,6 +9402,8 @@ tabpagenr([{arg}]) *tabpagenr()*
93819402
previous tab page 0 is returned.
93829403
The number can be used with the |:tab| command.
93839404

9405+
Returns zero on error.
9406+
93849407

93859408
tabpagewinnr({tabarg} [, {arg}]) *tabpagewinnr()*
93869409
Like |winnr()| but for tab page {tabarg}.
@@ -9453,6 +9476,7 @@ tan({expr}) *tan()*
94539476
Return the tangent of {expr}, measured in radians, as a |Float|
94549477
in the range [-inf, inf].
94559478
{expr} must evaluate to a |Float| or a |Number|.
9479+
Returns 0.0 if {expr} is not a |Float| or a |Number|.
94569480
Examples: >
94579481
:echo tan(10)
94589482
< 0.648361 >
@@ -9469,6 +9493,7 @@ tanh({expr}) *tanh()*
94699493
Return the hyperbolic tangent of {expr} as a |Float| in the
94709494
range [-1, 1].
94719495
{expr} must evaluate to a |Float| or a |Number|.
9496+
Returns 0.0 if {expr} is not a |Float| or a |Number|.
94729497
Examples: >
94739498
:echo tanh(0.5)
94749499
< 0.462117 >
@@ -9598,6 +9623,8 @@ timer_start({time}, {callback} [, {options}])
95989623
Vim becomes unusable because of all the error
95999624
messages.
96009625

9626+
Returns -1 on error.
9627+
96019628
Example: >
96029629
func MyHandler(timer)
96039630
echo 'Handler called'
@@ -9633,15 +9660,15 @@ timer_stopall() *timer_stopall()*
96339660
tolower({expr}) *tolower()*
96349661
The result is a copy of the String given, with all uppercase
96359662
characters turned into lowercase (just like applying |gu| to
9636-
the string).
9663+
the string). Returns an empty string on error.
96379664

96389665
Can also be used as a |method|: >
96399666
GetText()->tolower()
96409667
96419668
toupper({expr}) *toupper()*
96429669
The result is a copy of the String given, with all lowercase
96439670
characters turned into uppercase (just like applying |gU| to
9644-
the string).
9671+
the string). Returns an empty string on error.
96459672

96469673
Can also be used as a |method|: >
96479674
GetText()->toupper()
@@ -9654,6 +9681,8 @@ tr({src}, {fromstr}, {tostr}) *tr()*
96549681
and so on. Exactly like the unix "tr" command.
96559682
This code also deals with multibyte characters properly.
96569683

9684+
Returns an empty string on error.
9685+
96579686
Examples: >
96589687
echo tr("hello there", "ht", "HT")
96599688
< returns "Hello THere" >
@@ -9679,6 +9708,7 @@ trim({text} [, {mask} [, {dir}]]) *trim()*
96799708
When omitted both ends are trimmed.
96809709

96819710
This function deals with multibyte characters properly.
9711+
Returns an empty string on error.
96829712

96839713
Examples: >
96849714
echo trim(" some text ")
@@ -9697,6 +9727,7 @@ trunc({expr}) *trunc()*
96979727
Return the largest integral value with magnitude less than or
96989728
equal to {expr} as a |Float| (truncate towards zero).
96999729
{expr} must evaluate to a |Float| or a |Number|.
9730+
Returns 0.0 if {expr} is not a |Float| or a |Number|.
97009731
Examples: >
97019732
echo trunc(1.456)
97029733
< 1.0 >
@@ -9815,12 +9846,15 @@ uniq({list} [, {func} [, {dict}]]) *uniq()* *E882*
98159846
< The default compare function uses the string representation of
98169847
each item. For the use of {func} and {dict} see |sort()|.
98179848

9849+
Returns zero if {list} is not a |List|.
9850+
98189851
Can also be used as a |method|: >
98199852
mylist->uniq()
98209853
98219854
values({dict}) *values()*
98229855
Return a |List| with all the values of {dict}. The |List| is
98239856
in arbitrary order. Also see |items()| and |keys()|.
9857+
Returns zero if {dict} is not a |Dict|.
98249858

98259859
Can also be used as a |method|: >
98269860
mydict->values()
@@ -9988,6 +10022,8 @@ win_gettype([{nr}]) *win_gettype()*
998810022
popup window then 'buftype' is "terminal" and win_gettype()
998910023
returns "popup".
999010024

10025+
Return an empty string if the window cannot be found.
10026+
999110027
Can also be used as a |method|: >
999210028
GetWinid()->win_gettype()
999310029
<
@@ -10025,6 +10061,8 @@ win_move_separator({nr}, {offset}) *win_move_separator()*
1002510061
specified (e.g., as a consequence of maintaining
1002610062
'winminwidth'). Returns TRUE if the window can be found and
1002710063
FALSE otherwise.
10064+
This will fail for the rightmost window and a full-width
10065+
window, since it has no separator on the right.
1002810066

1002910067
Can also be used as a |method|: >
1003010068
GetWinnr()->win_move_separator(offset)

runtime/doc/channel.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1485,7 +1485,7 @@ request to the LSP server (if needed). Example: >
14851485
let resp = ch_sendexpr(ch, req, #{callback: 'HoverFunc'})
14861486
14871487
To cancel an outstanding asynchronous LSP request sent to the server using the
1488-
|ch_sendexpr()| function, send a cancelation message to the server using the
1488+
|ch_sendexpr()| function, send a cancellation message to the server using the
14891489
|ch_sendexpr()| function with the ID returned by the |ch_sendexpr()| function
14901490
for the request. Example: >
14911491
@@ -1533,7 +1533,7 @@ A LSP request message has the following format (expressed as a Vim Dict). The
15331533
"params": <list|dict>
15341534
}
15351535
1536-
A LSP reponse message has the following format (expressed as a Vim Dict). The
1536+
A LSP response message has the following format (expressed as a Vim Dict). The
15371537
"result" and "error" fields are optional: >
15381538
15391539
{
@@ -1565,7 +1565,7 @@ A LSP request message has the following format (expressed as a Vim Dict). The
15651565
"params": <list|dict>
15661566
}
15671567
1568-
A LSP reponse message has the following format (expressed as a Vim Dict). The
1568+
A LSP response message has the following format (expressed as a Vim Dict). The
15691569
"result" and "error" fields are optional: >
15701570
15711571
{

runtime/doc/cmdline.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*cmdline.txt* For Vim version 8.2. Last change: 2022 Apr 29
1+
*cmdline.txt* For Vim version 8.2. Last change: 2022 Jun 16
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -1218,8 +1218,8 @@ save the command-line history and read it back later.
12181218
If the 'wildchar' option is set to <Tab>, and the command-line window is used
12191219
for an Ex command, then two mappings will be added to use <Tab> for completion
12201220
in the command-line window, like this: >
1221-
:imap <buffer> <Tab> <C-X><C-V>
1222-
:nmap <buffer> <Tab> a<C-X><C-V>
1221+
:inoremap <buffer> <Tab> <C-X><C-V>
1222+
:nnoremap <buffer> <Tab> a<C-X><C-V>
12231223
Note that hitting <Tab> in Normal mode will do completion on the next
12241224
character. That way it works at the end of the line.
12251225
If you don't want these mappings, disable them with: >

runtime/doc/eval.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -531,7 +531,7 @@ entry. Note that the String '04' and the Number 04 are different, since the
531531
Number will be converted to the String '4', leading zeros are dropped. The
532532
empty string can also be used as a key.
533533

534-
In |Vim9| script literaly keys can be used if the key consists of alphanumeric
534+
In |Vim9| script literally keys can be used if the key consists of alphanumeric
535535
characters, underscore and dash, see |vim9-literal-dict|.
536536
*literal-Dict* *#{}*
537537
To avoid having to put quotes around every key the #{} form can be used in
@@ -1144,7 +1144,7 @@ expr6 >> expr6 bitwise right shift *expr->>*
11441144
The "<<" and ">>" operators can be used to perform bitwise left or right shift
11451145
of the left operand by the number of bits specified by the right operand. The
11461146
operands are used as positive numbers. When shifting right with ">>" the
1147-
topmost bit (somtimes called the sign bit) is cleared. If the right operand
1147+
topmost bit (sometimes called the sign bit) is cleared. If the right operand
11481148
(shift amount) is more than the maximum number of bits in a number
11491149
(|v:numbersize|) the result is zero.
11501150

runtime/doc/filetype.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -642,15 +642,15 @@ manpages and follows linked manpages on hitting CTRL-]).
642642

643643
For bash,zsh,ksh or dash, add to the config file (.bashrc,.zshrc, ...)
644644

645-
export MANPAGER="vim -M +MANPAGER -"
645+
export MANPAGER="vim +MANPAGER --not-a-term -"
646646

647647
For (t)csh, add to the config file
648648

649-
setenv MANPAGER "vim -M +MANPAGER -"
649+
setenv MANPAGER "vim +MANPAGER --not-a-term -"
650650

651651
For fish, add to the config file
652652

653-
set -x MANPAGER "vim -M +MANPAGER -"
653+
set -x MANPAGER "vim +MANPAGER --not-a-term -"
654654

655655

656656
MARKDOWN *ft-markdown-plugin*

0 commit comments

Comments
 (0)