aboutsummaryrefslogtreecommitdiff
path: root/runtime/pack
diff options
context:
space:
mode:
authorJosh Rahm <joshuarahm@gmail.com>2024-05-24 19:18:11 +0000
committerJosh Rahm <joshuarahm@gmail.com>2024-05-24 19:18:11 +0000
commitff7ed8f586589d620a806c3758fac4a47a8e7e15 (patch)
tree729bbcb92231538fa61dab6c3d890b025484b7f5 /runtime/pack
parent376914f419eb08fdf4c1a63a77e1f035898a0f10 (diff)
parent28c04948a1c887a1cc0cb64de79fa32631700466 (diff)
downloadrneovim-ff7ed8f586589d620a806c3758fac4a47a8e7e15.tar.gz
rneovim-ff7ed8f586589d620a806c3758fac4a47a8e7e15.tar.bz2
rneovim-ff7ed8f586589d620a806c3758fac4a47a8e7e15.zip
Merge remote-tracking branch 'upstream/master' into mix_20240309
Diffstat (limited to 'runtime/pack')
-rw-r--r--runtime/pack/dist/opt/matchit/autoload/matchit.vim12
-rw-r--r--runtime/pack/dist/opt/matchit/doc/matchit.txt6
-rw-r--r--runtime/pack/dist/opt/matchit/plugin/matchit.vim4
-rw-r--r--runtime/pack/dist/opt/termdebug/plugin/termdebug.vim24
4 files changed, 34 insertions, 12 deletions
diff --git a/runtime/pack/dist/opt/matchit/autoload/matchit.vim b/runtime/pack/dist/opt/matchit/autoload/matchit.vim
index dc2aba696d..aa977488e5 100644
--- a/runtime/pack/dist/opt/matchit/autoload/matchit.vim
+++ b/runtime/pack/dist/opt/matchit/autoload/matchit.vim
@@ -1,6 +1,6 @@
" matchit.vim: (global plugin) Extended "%" matching
" autload script of matchit plugin, see ../plugin/matchit.vim
-" Last Change: Jan 24, 2022
+" Last Change: May 20, 2024
" Neovim does not support scriptversion
if has("vimscript-4")
@@ -87,9 +87,9 @@ function matchit#Match_wrapper(word, forward, mode) range
let s:last_mps = &mps
" quote the special chars in 'matchpairs', replace [,:] with \| and then
" append the builtin pairs (/*, */, #if, #ifdef, #ifndef, #else, #elif,
- " #endif)
+ " #elifdef, #elifndef, #endif)
let default = escape(&mps, '[$^.*~\\/?]') .. (strlen(&mps) ? "," : "") ..
- \ '\/\*:\*\/,#\s*if\%(n\=def\)\=:#\s*else\>:#\s*elif\>:#\s*endif\>'
+ \ '\/\*:\*\/,#\s*if\%(n\=def\)\=:#\s*else\>:#\s*elif\%(n\=def\)\=\>:#\s*endif\>'
" s:all = pattern with all the keywords
let match_words = match_words .. (strlen(match_words) ? "," : "") .. default
let s:last_words = match_words
@@ -101,6 +101,8 @@ function matchit#Match_wrapper(word, forward, mode) range
let s:pat = s:ParseWords(match_words)
endif
let s:all = substitute(s:pat, s:notslash .. '\zs[,:]\+', '\\|', 'g')
+ " un-escape \, to ,
+ let s:all = substitute(s:all, '\\,', ',', 'g')
" Just in case there are too many '\(...)' groups inside the pattern, make
" sure to use \%(...) groups, so that error E872 can be avoided
let s:all = substitute(s:all, '\\(', '\\%(', 'g')
@@ -112,6 +114,8 @@ function matchit#Match_wrapper(word, forward, mode) range
let s:patBR = substitute(match_words .. ',',
\ s:notslash .. '\zs[,:]*,[,:]*', ',', 'g')
let s:patBR = substitute(s:patBR, s:notslash .. '\zs:\{2,}', ':', 'g')
+ " un-escape \, to ,
+ let s:patBR = substitute(s:patBR, '\\,', ',', 'g')
endif
" Second step: set the following local variables:
@@ -534,6 +538,8 @@ fun! s:Choose(patterns, string, comma, branch, prefix, suffix, ...)
else
let currpat = substitute(current, s:notslash .. a:branch, '\\|', 'g')
endif
+ " un-escape \, to ,
+ let currpat = substitute(currpat, '\\,', ',', 'g')
while a:string !~ a:prefix .. currpat .. a:suffix
let tail = strpart(tail, i)
let i = matchend(tail, s:notslash .. a:comma)
diff --git a/runtime/pack/dist/opt/matchit/doc/matchit.txt b/runtime/pack/dist/opt/matchit/doc/matchit.txt
index 88d0c38e4d..8d56df6ddc 100644
--- a/runtime/pack/dist/opt/matchit/doc/matchit.txt
+++ b/runtime/pack/dist/opt/matchit/doc/matchit.txt
@@ -4,7 +4,7 @@ For instructions on installing this file, type
`:help matchit-install`
inside Vim.
-For Vim version 9.0. Last change: 2023 June 28
+For Vim version 9.1. Last change: 2024 May 20
VIM REFERENCE MANUAL by Benji Fisher et al
@@ -176,8 +176,8 @@ defined automatically.
2.1 Temporarily disable the matchit plugin *matchit-disable* *:MatchDisable*
-To temporarily reset the plugins, that are setup you can run the following
-command: >
+To temporarily disable the matchit plugin, after it hat been loaded,
+execute this command: >
:MatchDisable
This will delete all the defined key mappings to the Vim default.
diff --git a/runtime/pack/dist/opt/matchit/plugin/matchit.vim b/runtime/pack/dist/opt/matchit/plugin/matchit.vim
index d6c735d7b4..08fee09642 100644
--- a/runtime/pack/dist/opt/matchit/plugin/matchit.vim
+++ b/runtime/pack/dist/opt/matchit/plugin/matchit.vim
@@ -1,7 +1,7 @@
" matchit.vim: (global plugin) Extended "%" matching
" Maintainer: Christian Brabandt
-" Version: 1.19
-" Last Change: 2023, June 28th
+" Version: 1.20
+" Last Change: 2024 May 20
" Repository: https://github.com/chrisbra/matchit
" Previous URL:http://www.vim.org/script.php?script_id=39
" Previous Maintainer: Benji Fisher PhD <benji@member.AMS.org>
diff --git a/runtime/pack/dist/opt/termdebug/plugin/termdebug.vim b/runtime/pack/dist/opt/termdebug/plugin/termdebug.vim
index a253acc63f..f78a082cb7 100644
--- a/runtime/pack/dist/opt/termdebug/plugin/termdebug.vim
+++ b/runtime/pack/dist/opt/termdebug/plugin/termdebug.vim
@@ -427,7 +427,17 @@ func s:StartDebug_prompt(dict)
let s:promptbuf = bufnr('')
call prompt_setprompt(s:promptbuf, 'gdb> ')
set buftype=prompt
- file gdb
+
+ if empty(glob('gdb'))
+ file gdb
+ elseif empty(glob('Termdebug-gdb-console'))
+ file Termdebug-gdb-console
+ else
+ call s:Echoerr("You have a file/folder named 'gdb'
+ \ or 'Termdebug-gdb-console'.
+ \ Please exit and rename them because Termdebug may not work as expected.")
+ endif
+
call prompt_setcallback(s:promptbuf, function('s:PromptCallback'))
call prompt_setinterrupt(s:promptbuf, function('s:PromptInterrupt'))
@@ -1481,9 +1491,12 @@ func s:GotoAsmwinOrCreateIt()
if s:asmbuf > 0 && bufexists(s:asmbuf)
exe 'buffer' . s:asmbuf
- else
+ elseif empty(glob('Termdebug-asm-listing'))
silent file Termdebug-asm-listing
let s:asmbuf = bufnr('Termdebug-asm-listing')
+ else
+ call s:Echoerr("You have a file/folder named 'Termdebug-asm-listing'.
+ \ Please exit and rename it because Termdebug may not work as expected.")
endif
if mdf != 'vert' && s:GetDisasmWindowHeight() > 0
@@ -1550,9 +1563,12 @@ func s:GotoVariableswinOrCreateIt()
if s:varbuf > 0 && bufexists(s:varbuf)
exe 'buffer' . s:varbuf
- else
+ elseif empty(glob('Termdebug-variables-listing'))
silent file Termdebug-variables-listing
let s:varbuf = bufnr('Termdebug-variables-listing')
+ else
+ call s:Echoerr("You have a file/folder named 'Termdebug-variables-listing'.
+ \ Please exit and rename it because Termdebug may not work as expected.")
endif
if mdf != 'vert' && s:GetVariablesWindowHeight() > 0
@@ -1679,7 +1695,7 @@ func s:CreateBreakpoint(id, subid, enabled)
endif
endif
call sign_define('debugBreakpoint' .. nr,
- \ #{text: strpart(label, 0, 2),
+ \ #{text: slice(label, 0, 2),
\ texthl: hiName})
endif
endfunc