aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/_meta/vimfn.lua
diff options
context:
space:
mode:
authorJosh Rahm <joshuarahm@gmail.com>2024-11-25 19:15:05 +0000
committerJosh Rahm <joshuarahm@gmail.com>2024-11-25 19:27:38 +0000
commitc5d770d311841ea5230426cc4c868e8db27300a8 (patch)
treedd21f70127b4b8b5f109baefc8ecc5016f507c91 /runtime/lua/vim/_meta/vimfn.lua
parent9be89f131f87608f224f0ee06d199fcd09d32176 (diff)
parent081beb3659bd6d8efc3e977a160b1e72becbd8a2 (diff)
downloadrneovim-c5d770d311841ea5230426cc4c868e8db27300a8.tar.gz
rneovim-c5d770d311841ea5230426cc4c868e8db27300a8.tar.bz2
rneovim-c5d770d311841ea5230426cc4c868e8db27300a8.zip
Merge remote-tracking branch 'upstream/master' into mix_20240309
Diffstat (limited to 'runtime/lua/vim/_meta/vimfn.lua')
-rw-r--r--runtime/lua/vim/_meta/vimfn.lua43
1 files changed, 28 insertions, 15 deletions
diff --git a/runtime/lua/vim/_meta/vimfn.lua b/runtime/lua/vim/_meta/vimfn.lua
index 3f6deba092..5eb15e1eee 100644
--- a/runtime/lua/vim/_meta/vimfn.lua
+++ b/runtime/lua/vim/_meta/vimfn.lua
@@ -221,16 +221,16 @@ function vim.fn.assert_beeps(cmd) end
--- @return 0|1
function vim.fn.assert_equal(expected, actual, msg) end
---- When the files {fname-one} and {fname-two} do not contain
+--- When the files {fname_one} and {fname_two} do not contain
--- exactly the same text an error message is added to |v:errors|.
--- Also see |assert-return|.
---- When {fname-one} or {fname-two} does not exist the error will
+--- When {fname_one} or {fname_two} does not exist the error will
--- mention that.
---
---- @param fname-one string
---- @param fname-two string
+--- @param fname_one string
+--- @param fname_two string
--- @return 0|1
-function vim.fn.assert_equalfile(fname-one, fname-two) end
+function vim.fn.assert_equalfile(fname_one, fname_two) end
--- When v:exception does not contain the string {error} an error
--- message is added to |v:errors|. Also see |assert-return|.
@@ -809,7 +809,7 @@ function vim.fn.char2nr(string, utf8) end
--- The character class is one of:
--- 0 blank
--- 1 punctuation
---- 2 word character
+--- 2 word character (depends on 'iskeyword')
--- 3 emoji
--- other specific Unicode class
--- The class is used in patterns and word motions.
@@ -828,7 +828,7 @@ function vim.fn.charclass(string) end
--- echo col('.') " returns 7
--- <
---
---- @param expr string|integer[]
+--- @param expr string|any[]
--- @param winid? integer
--- @return integer
function vim.fn.charcol(expr, winid) end
@@ -956,7 +956,7 @@ function vim.fn.clearmatches(win) end
--- imap <F2> <Cmd>echo col(".").."\n"<CR>
--- <
---
---- @param expr string|integer[]
+--- @param expr string|any[]
--- @param winid? integer
--- @return integer
function vim.fn.col(expr, winid) end
@@ -2879,12 +2879,22 @@ function vim.fn.getcharsearch() end
--- @return string
function vim.fn.getcharstr(expr) end
+--- Return completion pattern of the current command-line.
+--- Only works when the command line is being edited, thus
+--- requires use of |c_CTRL-\_e| or |c_CTRL-R_=|.
+--- Also see |getcmdtype()|, |setcmdpos()|, |getcmdline()|,
+--- |getcmdprompt()|, |getcmdcompltype()| and |setcmdline()|.
+--- Returns an empty string when completion is not defined.
+---
+--- @return string
+function vim.fn.getcmdcomplpat() end
+
--- Return the type of the current command-line completion.
--- Only works when the command line is being edited, thus
--- requires use of |c_CTRL-\_e| or |c_CTRL-R_=|.
--- See |:command-completion| for the return string.
--- Also see |getcmdtype()|, |setcmdpos()|, |getcmdline()|,
---- |getcmdprompt()| and |setcmdline()|.
+--- |getcmdprompt()|, |getcmdcomplpat()| and |setcmdline()|.
--- Returns an empty string when completion is not defined.
---
--- @return string
@@ -2998,6 +3008,7 @@ function vim.fn.getcmdwintype() end
--- runtime |:runtime| completion
--- scriptnames sourced script names |:scriptnames|
--- shellcmd Shell command
+--- shellcmdline Shell command line with filename arguments
--- sign |:sign| suboptions
--- syntax syntax file names |'syntax'|
--- syntime |:syntime| suboptions
@@ -5181,7 +5192,7 @@ function vim.fn.log(expr) end
function vim.fn.log10(expr) end
--- {expr1} must be a |List|, |String|, |Blob| or |Dictionary|.
---- When {expr1} is a |List|| or |Dictionary|, replace each
+--- When {expr1} is a |List| or |Dictionary|, replace each
--- item in {expr1} with the result of evaluating {expr2}.
--- For a |Blob| each byte is replaced.
--- For a |String|, each character, including composing
@@ -7912,7 +7923,7 @@ function vim.fn.setbufvar(buf, varname, val) end
--- To clear the overrides pass an empty {list}: >vim
--- call setcellwidths([])
---
---- <You can use the script $VIMRUNTIME/tools/emoji_list.lua to see
+--- <You can use the script $VIMRUNTIME/scripts/emoji_list.lua to see
--- the effect for known emoji characters. Move the cursor
--- through the text to check if the cell widths of your terminal
--- match with what Vim knows about each emoji. If it doesn't
@@ -8218,6 +8229,8 @@ function vim.fn.setpos(expr, list) end
--- clear the list: >vim
--- call setqflist([], 'r')
--- <
+--- 'u' Like 'r', but tries to preserve the current selection
+--- in the quickfix list.
--- 'f' All the quickfix lists in the quickfix stack are
--- freed.
---
@@ -8273,9 +8286,9 @@ function vim.fn.setpos(expr, list) end
--- independent of the 'errorformat' setting. Use a command like
--- `:cc 1` to jump to the first position.
---
---- @param list any[]
+--- @param list vim.quickfix.entry[]
--- @param action? string
---- @param what? table
+--- @param what? vim.fn.setqflist.what
--- @return any
function vim.fn.setqflist(list, action, what) end
@@ -10533,7 +10546,7 @@ function vim.fn.values(dict) end
--- echo max(map(range(1, line('$')), "virtcol([v:val, '$'])"))
--- <
---
---- @param expr string|integer[]
+--- @param expr string|any[]
--- @param list? boolean
--- @param winid? integer
--- @return any
@@ -10616,7 +10629,7 @@ function vim.fn.wait(timeout, condition, interval) end
--- For example to make <c-j> work like <down> in wildmode, use: >vim
--- cnoremap <expr> <C-j> wildmenumode() ? "\<Down>\<Tab>" : "\<c-j>"
--- <
---- (Note, this needs the 'wildcharm' option set appropriately).
+--- (Note: this needs the 'wildcharm' option set appropriately).
---
--- @return any
function vim.fn.wildmenumode() end