vim-patch:partial:f10911e: Update runtime files (#29936)

f10911e5db

Also cherry-pick E1142 and E1156 tags from Vim.

Co-authored-by: Bram Moolenaar <Bram@vim.org>
This commit is contained in:
zeertzjq 2024-08-01 11:50:38 +08:00 committed by GitHub
parent 02eaf7c4c1
commit 2b4049719a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
9 changed files with 42 additions and 11 deletions

View File

@ -224,12 +224,12 @@ assert_fails({cmd} [, {error} [, {msg} [, {lnum} [, {context}]]]])
<
If {msg} is empty then it is not used. Do this to get the
default message when passing the {lnum} argument.
*E1115*
When {lnum} is present and not negative, and the {error}
argument is present and matches, then this is compared with
the line number at which the error was reported. That can be
the line number in a function or in a script.
*E1116*
When {context} is present it is used as a pattern and matched
against the context (script name or function name) where
{lnum} is located in.
@ -8498,7 +8498,7 @@ test_garbagecollect_now() *test_garbagecollect_now()*
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. *E1142*
timer_info([{id}]) *timer_info()*
Return a list with information about timers.

View File

@ -646,7 +646,7 @@ list of the current window.
Also see |++opt| and |+cmd|.
:[count]arga[dd] {name} .. *:arga* *:argadd* *E479*
:[count]arga[dd]
:[count]arga[dd] *E1156*
Add the {name}s to the argument list. When {name} is
omitted add the current buffer name to the argument
list.

View File

@ -894,6 +894,9 @@ Example: >
All expressions within one level are parsed from left to right.
Expression nesting is limited to 1000 levels deep (300 when build with MSVC)
to avoid running out of stack and crashing. *E1169*
------------------------------------------------------------------------------
expr1 *expr1* *ternary* *falsy-operator* *??* *E109*
@ -2187,7 +2190,7 @@ text...
:lockvar v
:let v = 'asdf' " fails!
:unlet v " works
< *E741* *E940*
< *E741* *E940* *E1122*
If you try to change a locked variable you get an
error message: "E741: Value is locked: {name}".
If you try to lock or unlock a built-in variable you

View File

@ -690,6 +690,7 @@ Ex command or function was given an invalid argument. Or |jobstart()| or
*E488* >
Trailing characters
Trailing characters: {text}
An argument was given to an Ex command that does not permit one.
Or the argument has invalid characters and has not been recognized.
@ -756,7 +757,7 @@ src/ex_cmds.lua. Update the lookup table by re-running the build. >
This is an (incomplete) overview of various messages that Vim gives:
*hit-enter* *press-enter* *hit-return*
*press-return* *hit-enter-prompt*
*press-return* *hit-enter-prompt* >
Press ENTER or type command to continue

View File

@ -1299,6 +1299,14 @@ A jump table for the options with a short description can be found at |Q_op|.
v:fname_in name of the input file
v:fname_out name of the output file
Note that v:fname_in and v:fname_out will never be the same.
If the 'charconvert' expression starts with s: or |<SID>|, then it is
replaced with the script ID (|local-function|). Example: >vim
set charconvert=s:MyConvert()
set charconvert=<SID>SomeConvert()
< Otherwise the expression is evaluated in the context of the script
where the option was set, thus script-local items are available.
This option cannot be set from a |modeline| or in the |sandbox|, for
security reasons.

View File

@ -785,6 +785,17 @@ vim.bo.channel = vim.o.channel
--- v:fname_in name of the input file
--- v:fname_out name of the output file
--- Note that v:fname_in and v:fname_out will never be the same.
---
--- If the 'charconvert' expression starts with s: or `<SID>`, then it is
--- replaced with the script ID (`local-function`). Example:
---
--- ```vim
--- set charconvert=s:MyConvert()
--- set charconvert=<SID>SomeConvert()
--- ```
--- Otherwise the expression is evaluated in the context of the script
--- where the option was set, thus script-local items are available.
---
--- This option cannot be set from a `modeline` or in the `sandbox`, for
--- security reasons.
---

View File

@ -268,12 +268,12 @@ function vim.fn.assert_exception(error, msg) end
--- <
--- If {msg} is empty then it is not used. Do this to get the
--- default message when passing the {lnum} argument.
---
--- *E1115*
--- When {lnum} is present and not negative, and the {error}
--- argument is present and matches, then this is compared with
--- the line number at which the error was reported. That can be
--- the line number in a function or in a script.
---
--- *E1116*
--- When {context} is present it is used as a pattern and matched
--- against the context (script name or function name) where
--- {lnum} is located in.

View File

@ -380,12 +380,12 @@ M.funcs = {
<
If {msg} is empty then it is not used. Do this to get the
default message when passing the {lnum} argument.
*E1115*
When {lnum} is present and not negative, and the {error}
argument is present and matches, then this is compared with
the line number at which the error was reported. That can be
the line number in a function or in a script.
*E1116*
When {context} is present it is used as a pattern and matched
against the context (script name or function name) where
{lnum} is located in.
@ -12058,7 +12058,7 @@ M.funcs = {
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. *E1142*
]=],
params = {},
signature = 'test_garbagecollect_now()',

View File

@ -1058,6 +1058,14 @@ return {
v:fname_in name of the input file
v:fname_out name of the output file
Note that v:fname_in and v:fname_out will never be the same.
If the 'charconvert' expression starts with s: or |<SID>|, then it is
replaced with the script ID (|local-function|). Example: >vim
set charconvert=s:MyConvert()
set charconvert=<SID>SomeConvert()
< Otherwise the expression is evaluated in the context of the script
where the option was set, thus script-local items are available.
This option cannot be set from a |modeline| or in the |sandbox|, for
security reasons.
]=],