aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--runtime/doc/builtin.txt1
-rw-r--r--runtime/lua/vim/_meta/vimfn.lua1
-rw-r--r--src/nvim/eval.lua1
3 files changed, 3 insertions, 0 deletions
diff --git a/runtime/doc/builtin.txt b/runtime/doc/builtin.txt
index 1a7efc3d79..3df24a3b5f 100644
--- a/runtime/doc/builtin.txt
+++ b/runtime/doc/builtin.txt
@@ -6054,6 +6054,7 @@ search({pattern} [, {flags} [, {stopline} [, {timeout} [, {skip}]]]]) *search()*
When a match has been found its line number is returned.
If there is no match a 0 is returned and the cursor doesn't
move. No error message is given.
+ To get the matched string, use |matchbufline()|.
{flags} is a String, which can contain these character flags:
'b' search Backward instead of forward
diff --git a/runtime/lua/vim/_meta/vimfn.lua b/runtime/lua/vim/_meta/vimfn.lua
index a51f89227b..2b93ea7d4e 100644
--- a/runtime/lua/vim/_meta/vimfn.lua
+++ b/runtime/lua/vim/_meta/vimfn.lua
@@ -7259,6 +7259,7 @@ function vim.fn.screenstring(row, col) end
--- When a match has been found its line number is returned.
--- If there is no match a 0 is returned and the cursor doesn't
--- move. No error message is given.
+--- To get the matched string, use |matchbufline()|.
---
--- {flags} is a String, which can contain these character flags:
--- 'b' search Backward instead of forward
diff --git a/src/nvim/eval.lua b/src/nvim/eval.lua
index 73715e2631..96dc32259f 100644
--- a/src/nvim/eval.lua
+++ b/src/nvim/eval.lua
@@ -8746,6 +8746,7 @@ M.funcs = {
When a match has been found its line number is returned.
If there is no match a 0 is returned and the cursor doesn't
move. No error message is given.
+ To get the matched string, use |matchbufline()|.
{flags} is a String, which can contain these character flags:
'b' search Backward instead of forward