Skip to content

Commit 0d3dfca

Browse files
committed
Merge remote-tracking branch 'vim/master'
2 parents 4d30606 + df069ee commit 0d3dfca

70 files changed

Lines changed: 1492 additions & 408 deletions

Some content is hidden

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

ci/appveyor.bat

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ cd src
88
echo "Building MinGW 32bit console version"
99
set PATH=c:\msys64\mingw32\bin;%PATH%
1010
mingw32-make.exe -f Make_ming.mak GUI=no OPTIMIZE=speed IME=yes ICONV=yes DEBUG=no FEATURES=%FEATURE% || exit 1
11+
.\vim -u NONE -c "redir @a | ver |0put a | wq" ver_ming.txt
1112
:: Save vim.exe before Make clean, moved back below.
1213
copy vim.exe testdir
1314
mingw32-make.exe -f Make_ming.mak clean
@@ -20,13 +21,14 @@ if "%FEATURE%" == "HUGE" (
2021
) ELSE (
2122
mingw32-make.exe -f Make_ming.mak OPTIMIZE=speed GUI=yes IME=yes ICONV=yes DEBUG=no FEATURES=%FEATURE% || exit 1
2223
)
23-
.\gvim -u NONE -c "redir @a | ver |0put a | wq" ver_ming.txt
24+
.\gvim -u NONE -c "redir @a | ver |0put a | wq" ver_ming_gui.txt
2425

2526
:: Filter out the progress bar from the build log
2627
sed -e "s/@<<$/@<< | sed -e 's#.*\\\\r.*##'/" Make_mvc.mak > Make_mvc2.mak
2728

2829
echo "Building MSVC 64bit console Version"
2930
nmake -f Make_mvc2.mak CPU=AMD64 OLE=no GUI=no IME=yes ICONV=yes DEBUG=no FEATURES=%FEATURE% || exit 1
31+
:: The executable is not used
3032
nmake -f Make_mvc2.mak clean
3133

3234
:: build MSVC huge version with python and channel support
@@ -43,6 +45,8 @@ if "%FEATURE%" == "HUGE" (
4345
move /Y testdir\vim.exe .
4446
echo "version output MinGW"
4547
type ver_ming.txt
48+
echo "version output MinGW GUI"
49+
type ver_ming_gui.txt
4650
echo "version output MVC"
4751
type ver_msvc.txt
4852
cd ..

runtime/doc/eval.txt

Lines changed: 17 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*eval.txt* For Vim version 8.2. Last change: 2020 Jun 14
1+
*eval.txt* For Vim version 8.2. Last change: 2020 Jun 17
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -3679,7 +3679,7 @@ complete_info([{what}])
36793679
"function" User defined completion |i_CTRL-X_CTRL-U|
36803680
"omni" Omni completion |i_CTRL-X_CTRL-O|
36813681
"spell" Spelling suggestions |i_CTRL-X_s|
3682-
"eval" |complete()| completion
3682+
"eval" |complete()| completion
36833683
"unknown" Other internal modes
36843684

36853685
If the optional {what} list argument is supplied, then only
@@ -4548,7 +4548,7 @@ flatten({list} [, {maxdepth}]) *flatten()*
45484548
a very large number.
45494549
The {list} is changed in place, make a copy first if you do
45504550
not want that.
4551-
*E900*
4551+
*E900*
45524552
{maxdepth} means how deep in nested lists changes are made.
45534553
{list} is not modified when {maxdepth} is 0.
45544554
{maxdepth} must be positive number.
@@ -5175,7 +5175,7 @@ getcompletion({pat}, {type} [, {filtered}]) *getcompletion()*
51755175
highlight highlight groups
51765176
history :history suboptions
51775177
locale locale names (as output of locale -a)
5178-
mapclear buffer argument
5178+
mapclear buffer argument
51795179
mapping mapping name
51805180
menu menus
51815181
messages |:messages| suboptions
@@ -5201,7 +5201,7 @@ getcompletion({pat}, {type} [, {filtered}]) *getcompletion()*
52015201
If {type} is "cmdline", then the |cmdline-completion| result is
52025202
returned. For example, to complete the possible values after
52035203
a ":call" command: >
5204-
echo getcompletion('call ', 'cmdline')
5204+
echo getcompletion('call ', 'cmdline')
52055205
<
52065206
If there are no matches, an empty list is returned. An
52075207
invalid value for {type} produces an error.
@@ -5782,8 +5782,8 @@ getwininfo([{winid}]) *getwininfo()*
57825782
Returns information about windows as a List with Dictionaries.
57835783

57845784
If {winid} is given Information about the window with that ID
5785-
is returned. If the window does not exist the result is an
5786-
empty list.
5785+
is returned, as a List with one item. If the window does not
5786+
exist the result is an empty list.
57875787

57885788
Without {winid} information about all the windows in all the
57895789
tab pages is returned.
@@ -8618,14 +8618,14 @@ searchcount([{options}]) *searchcount()*
86188618
if result.total > result.maxcount &&
86198619
\ result.current > result.maxcount
86208620
return printf(' /%s [>%d/>%d]', @/,
8621-
\ result.current, result.total)
8621+
\ result.current, result.total)
86228622
elseif result.total > result.maxcount
86238623
return printf(' /%s [%d/>%d]', @/,
8624-
\ result.current, result.total)
8624+
\ result.current, result.total)
86258625
endif
86268626
endif
86278627
return printf(' /%s [%d/%d]', @/,
8628-
\ result.current, result.total)
8628+
\ result.current, result.total)
86298629
endfunction
86308630
let &statusline .= '%{LastSearchCount()}'
86318631

@@ -9398,7 +9398,9 @@ simplify({filename}) *simplify()*
93989398
Unix) are not resolved. If the first path component in
93999399
{filename} designates the current directory, this will be
94009400
valid for the result as well. A trailing path separator is
9401-
not removed either.
9401+
not removed either. On Unix "//path" is unchanged, but
9402+
"///path" is simplified to "/path" (this follows the Posix
9403+
standard).
94029404
Example: >
94039405
simplify("./dir/.././/file/") == "./file/"
94049406
< Note: The combination "dir/.." is only removed if "dir" is
@@ -9708,7 +9710,7 @@ state([{what}]) *state()*
97089710
m halfway a mapping, :normal command, feedkeys() or
97099711
stuffed command
97109712
o operator pending or waiting for a command argument,
9711-
e.g. after |f|
9713+
e.g. after |f|
97129714
a Insert mode autocomplete active
97139715
x executing an autocommand
97149716
w blocked on waiting, e.g. ch_evalexpr(), ch_read() and
@@ -10462,9 +10464,9 @@ terminalprops() *terminalprops()*
1046210464
If the |+termresponse| feature is missing then the result is
1046310465
an empty dictionary.
1046410466

10465-
If "cursor_style" is 'y' then |t_RS| will be send to request the
10467+
If "cursor_style" is 'y' then |t_RS| will be sent to request the
1046610468
current cursor style.
10467-
If "cursor_blink_mode" is 'y' then |t_RC| will be send to
10469+
If "cursor_blink_mode" is 'y' then |t_RC| will be sent to
1046810470
request the cursor blink status.
1046910471
"cursor_style" and "cursor_blink_mode" are also set if |t_u7|
1047010472
is not empty, Vim will detect the working of sending |t_RS|
@@ -10928,7 +10930,7 @@ win_screenpos({nr}) *win_screenpos()*
1092810930
GetWinid()->win_screenpos()
1092910931
<
1093010932
win_splitmove({nr}, {target} [, {options}]) *win_splitmove()*
10931-
Move the window {nr} to a new split of the window {target}.
10933+
Move the window {nr} to a new split of the window {target}.
1093210934
This is similar to moving to {target}, creating a new window
1093310935
using |:split| but having the same contents as window {nr}, and
1093410936
then closing {nr}.

runtime/doc/mlang.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*mlang.txt* For Vim version 8.2. Last change: 2019 May 05
1+
*mlang.txt* For Vim version 8.2. Last change: 2020 Jun 16
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar

runtime/doc/tags

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3951,6 +3951,7 @@ E105 mbyte.txt /*E105*
39513951
E107 eval.txt /*E107*
39523952
E108 eval.txt /*E108*
39533953
E109 eval.txt /*E109*
3954+
E1094 vim9.txt /*E1094*
39543955
E11 cmdline.txt /*E11*
39553956
E110 eval.txt /*E110*
39563957
E111 eval.txt /*E111*
@@ -5883,6 +5884,7 @@ coding-style develop.txt /*coding-style*
58835884
col() eval.txt /*col()*
58845885
coldfusion.vim syntax.txt /*coldfusion.vim*
58855886
collapse tips.txt /*collapse*
5887+
collate-variable eval.txt /*collate-variable*
58865888
color-xterm syntax.txt /*color-xterm*
58875889
coloring syntax.txt /*coloring*
58885890
colortest.vim syntax.txt /*colortest.vim*
@@ -9856,6 +9858,7 @@ v:charconvert_from eval.txt /*v:charconvert_from*
98569858
v:charconvert_to eval.txt /*v:charconvert_to*
98579859
v:cmdarg eval.txt /*v:cmdarg*
98589860
v:cmdbang eval.txt /*v:cmdbang*
9861+
v:collate eval.txt /*v:collate*
98599862
v:completed_item eval.txt /*v:completed_item*
98609863
v:count eval.txt /*v:count*
98619864
v:count1 eval.txt /*v:count1*

runtime/doc/testing.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*testing.txt* For Vim version 8.2. Last change: 2020 Jun 13
1+
*testing.txt* For Vim version 8.2. Last change: 2020 Jun 15
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar

runtime/doc/todo.txt

Lines changed: 13 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*todo.txt* For Vim version 8.2. Last change: 2020 Jun 14
1+
*todo.txt* For Vim version 8.2. Last change: 2020 Jun 21
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -40,16 +40,16 @@ browser use: https://github.com/vim/vim/issues/1234
4040

4141
Include src/po/vim.pot ?
4242

43+
See if resizing a terminal can be fixed.
44+
4345
Vim9 script:
4446
Making everything work:
45-
- assignment to script var should check type
46-
- Compile: let [var, var] = expr
47-
share code for :let between compiled and uncompiled?
48-
- do not allow "let g:var = value", must drop "let"
47+
- Error for "g:var: string = 'value'"
48+
- Make func()->append('$') work - value is last argument, not first. #6305
4949
- possible memory leak in test_vim9_func through compile_nested_function.
5050
- memory leaks in test_vim9_expr
5151
- memory leaks in test_vim9_script
52-
- Test that a script-local function in Vim9 script cannot be deleted.
52+
- more return types depending on the first argument, like sort().
5353
- Check that when sourcing a Vim9 script, only the global items can be used.
5454
- Make "true" and "false" work in vim9script
5555
- Test that a function defined inside a :def function is local to that
@@ -240,10 +240,12 @@ Terminal emulator window:
240240
conversions.
241241

242242
Error numbers available:
243-
E489, E610, E611, E653, E856, E857, E861
243+
E489, E610, E611, E653, E856
244244

245245
Remove SPACE_IN_FILENAME ? It is only used for completion.
246246

247+
Patch to use collaction based sorting. (Christian Brabandt, #6229)
248+
247249
Can we detect true color support? https://gist.github.com/XVilka/8346728
248250
Try setting a color then request the current color, like using t_u7.
249251

@@ -272,6 +274,8 @@ The buffer list and windows are locked, no changes possible
272274
How about removing Atari MiNT support?
273275
src/Make_mint.mak, src/os_mint.h, matches with __MINT__
274276

277+
Patch to make :q work with local arglist. (Christian Brabandt, #6286)
278+
275279
Patch to fix drawing error with DirectX. (James Grant, #5688)
276280
Causes flicker on resizing. Workaround from Ken Takata.
277281
How about only setting the attribute when part of the Vim window is offscreen?
@@ -285,6 +289,8 @@ Motif: Build on Ubuntu can't enter any text in dialog text fields.
285289
Running test_gui and test_gui_init with Motif sometimes kills the window
286290
manager. Problem with Motif?
287291

292+
Patch to add :argdedupe. (Nir Lichtman, #6235)
293+
288294
:map output does not clear the reset of the command line.
289295
(#5623, also see #5962)
290296

@@ -1402,9 +1408,6 @@ the system encoding (usually utf-8).
14021408
MS-Windows: use WS_HIDE instead of SW_SHOWMINNOACTIVE in os_win32.c?
14031409
Otherwise task flickers in taskbar.
14041410

1405-
Should make ":@r" handle line continuation. (Cesar Romani, 2016 Jun 26)
1406-
Also for ":@.".
1407-
14081411
Repeating 'opfunc' in a function only works once. (Tarmean, 2016 Jul 15, #925)
14091412

14101413
Have a way to get the call stack, in a function and from an exception.

runtime/doc/usr_11.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ will automatically delete it:
211211
- The flag that the file was modified is not set.
212212
- The process is not running.
213213

214-
You can programatically deal with this situation with the |FileChangedShell|
214+
You can programmatically deal with this situation with the |FileChangedShell|
215215
autocommand event.
216216

217217

runtime/doc/usr_46.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ Although it's shorter to do: >
112112

113113
Legacy Vim script does have type checking, but this happens at runtime, when
114114
the code is executed. And it's permissive, often a computation gives an
115-
unexpected value instead of reporting an error . Thus you can define a
115+
unexpected value instead of reporting an error. Thus you can define a
116116
function and think it's fine, but see a problem only later when it is called: >
117117
let s:collected = ''
118118
func ExtendAndReturn(add)
@@ -142,7 +142,7 @@ you did wrong: >
142142
143143
Vim9 script is strict, it uses the "+" operator only for numbers and floats.
144144
For string concatenation ".." must be used. This avoids mistakes and avoids
145-
the automatic conversion that gave a suprising result above. So you change
145+
the automatic conversion that gave a surprising result above. So you change
146146
the first line of the function to: >
147147
s:collected ..= add
148148
And now it works.

runtime/doc/usr_toc.txt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*usr_toc.txt* For Vim version 8.2. Last change: 2020 Jun 11
1+
*usr_toc.txt* For Vim version 8.2. Last change: 2020 Jun 15
22

33
VIM USER MANUAL - by Bram Moolenaar
44

@@ -340,6 +340,12 @@ Make Vim work as you like it.
340340
|45.4| Editing files with a different encoding
341341
|45.5| Entering language text
342342

343+
|usr_46.txt| Write plugins using Vim9 script
344+
|46.1| Introduction
345+
|46.2| Variable declarations
346+
|46.3| Functions and types
347+
|46.?| Using a Vim9 script from legacy script
348+
343349
==============================================================================
344350
Making Vim Run ~
345351

runtime/doc/vim9.txt

Lines changed: 31 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*vim9.txt* For Vim version 8.2. Last change: 2020 Jun 14
1+
*vim9.txt* For Vim version 8.2. Last change: 2020 Jun 22
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -30,7 +30,7 @@ THIS IS STILL UNDER DEVELOPMENT - ANYTHING CAN BREAK - ANYTHING CAN CHANGE
3030

3131
Vim script has been growing over time, while preserving backwards
3232
compatibility. That means bad choices from the past often can't be changed
33-
and compability with Vi restricts possible solutions. Execution is quite
33+
and compatibility with Vi restricts possible solutions. Execution is quite
3434
slow, each line is parsed every time it is executed.
3535

3636
The main goal of Vim9 script is to drastically improve performance. This is
@@ -68,7 +68,7 @@ In Vim script comments normally start with double quote. That can also be the
6868
start of a string, thus in many places it cannot be used. In Vim9 script a
6969
comment can also start with #. In Vi this is a command to list text with
7070
numbers, but you can also use `:number` for that. >
71-
let count = 0 # number of occurences
71+
let count = 0 # number of occurrences
7272
7373
To improve readability there must be a space between the command and the #
7474
that starts a comment. Note that #{ is the start of a dictionary, therefore
@@ -257,20 +257,32 @@ Function call: >
257257
arg2
258258
)
259259
260-
For binary operators iin expressions not in [], {} or () a line break is
261-
possible AFTER the operators. For example: >
262-
let text = lead ..
263-
middle ..
264-
end
260+
For binary operators in expressions not in [], {} or () a line break is
261+
possible just before or after the operator. For example: >
262+
let text = lead
263+
.. middle
264+
.. end
265265
let total = start +
266266
end -
267267
correction
268-
let result = positive ?
269-
PosFunc(arg) :
270-
NegFunc(arg)
271-
272-
Note that "enddef" cannot be used at the start of a continuation line, it ends
273-
the current function.
268+
let result = positive
269+
? PosFunc(arg)
270+
: NegFunc(arg)
271+
272+
let result = GetBuilder()
273+
->BuilderSetWidth(333)
274+
->BuilderSetHeight(777)
275+
->BuilderBuild()
276+
277+
< *E1050*
278+
To make it possible for the operator at the start of the line to be
279+
recognized, it is required to put a colon before a range. This will adde
280+
"start" and print: >
281+
let result = start
282+
+ print
283+
This will assign "start" and print a line: >
284+
let result = start
285+
:+ print
274286
275287
It is also possible to split a function header over multiple lines, in between
276288
arguments: >
@@ -279,6 +291,9 @@ arguments: >
279291
separator = '-'
280292
): string
281293
294+
Note that "enddef" cannot be used at the start of a continuation line, it ends
295+
the current function.
296+
282297

283298
No curly braces expansion ~
284299

@@ -566,7 +581,7 @@ defined (otherwise script-local) items: >
566581

567582

568583
Import ~
569-
*:import* *:imp*
584+
*:import* *:imp* *E1094*
570585
The exported items can be imported individually in another Vim9 script: >
571586
import EXPORTED_CONST from "thatscript.vim"
572587
import MyClass from "myclass.vim"
@@ -692,7 +707,7 @@ A, B and C, where A calls B, B calls C, and C calls A again. It's impossible
692707
to reorder the functions to avoid forward references.
693708

694709
An alternative would be to first scan through the file to locate items and
695-
figure out their type, so that forward refeferences are found, and only then
710+
figure out their type, so that forward references are found, and only then
696711
execute the script and compile the functions. This means the script has to be
697712
parsed twice, which is slower, and some conditions at the script level, such
698713
as checking if a feature is supported, are hard to use. An attempt was made

0 commit comments

Comments
 (0)