diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt index 338a27348e..a1aeeb8132 100644 --- a/runtime/doc/options.txt +++ b/runtime/doc/options.txt @@ -4319,7 +4319,8 @@ A jump table for the options with a short description can be found at |Q_op|. When the number of matches exceeds this value, Vim shows ">" instead of the exact count to keep searching fast. Note: larger values may impact performance. - The value must be between 1 and 9999. + The value must be between 1 and 9999. See also the |searchcount()| + function. *'menuitems'* *'mis'* 'menuitems' 'mis' number (default 25) @@ -5738,7 +5739,8 @@ A jump table for the options with a short description can be found at |Q_op|. "search hit TOP, continuing at BOTTOM" messages are only indicated by a "W" (Mnemonic: Wrapped) letter before the search count statistics. The maximum limit can be set with - the 'maxsearchcount' option. + the 'maxsearchcount' option, see also |searchcount()| + function. This gives you the opportunity to avoid that a change between buffers requires you to hit , but still gives as useful a message as diff --git a/runtime/doc/vimeval.txt b/runtime/doc/vimeval.txt index 8d96995082..d117d84d00 100644 --- a/runtime/doc/vimeval.txt +++ b/runtime/doc/vimeval.txt @@ -2419,12 +2419,15 @@ text... matching {pattern} is being thrown and has not yet been caught by a previous `:catch`. Otherwise, these commands are skipped. - When {pattern} is omitted all errors are caught. - Examples: > + Pattern can start with "Vim({cmd})" to indicate an + exception that occurred when executing the Ex command + {cmd}. When {pattern} is omitted all errors are + caught. Examples: > :catch /^Vim:Interrupt$/ " catch interrupts (CTRL-C) :catch /^Vim\%((\a\+)\)\=:E/ " catch all Vim errors :catch /^Vim\%((\a\+)\)\=:/ " catch errors and interrupts :catch /^Vim(write):/ " catch all errors in :write + :catch /^Vim(!):/ " catch all errors in :! :catch /^Vim\%((\a\+)\)\=:E123:/ " catch error E123 :catch /my-exception/ " catch user exception :catch /.*/ " catch everything diff --git a/runtime/ftplugin/bpftrace.vim b/runtime/ftplugin/bpftrace.vim index b9ad1d13c1..73772b103d 100644 --- a/runtime/ftplugin/bpftrace.vim +++ b/runtime/ftplugin/bpftrace.vim @@ -1,7 +1,7 @@ " Vim filetype plugin " Language: bpftrace " Maintainer: Stanislaw Gruszka -" Last Change: 2025 Dec 05 +" Last Change: 2025 Dec 23 if exists('b:did_ftplugin') finish @@ -11,4 +11,6 @@ let b:did_ftplugin = 1 setlocal comments=sO:*\ -,mO:*\ \ ,exO:*/,s1:/*,mb:*,ex:*/,:// setlocal commentstring=//\ %s -let b:undo_ftplugin = "setlocal comments< commentstring<" +setlocal formatoptions-=t formatoptions+=croql + +let b:undo_ftplugin = "setlocal comments< commentstring< formatoptions<" diff --git a/runtime/lua/vim/_meta/options.lua b/runtime/lua/vim/_meta/options.lua index 5e2f7191ee..5db4bf821a 100644 --- a/runtime/lua/vim/_meta/options.lua +++ b/runtime/lua/vim/_meta/options.lua @@ -4385,7 +4385,8 @@ vim.go.mmp = vim.go.maxmempattern --- When the number of matches exceeds this value, Vim shows ">" instead --- of the exact count to keep searching fast. --- Note: larger values may impact performance. ---- The value must be between 1 and 9999. +--- The value must be between 1 and 9999. See also the `searchcount()` +--- function. --- --- @type integer vim.o.maxsearchcount = 999 @@ -6073,7 +6074,8 @@ vim.bo.sw = vim.bo.shiftwidth --- "search hit TOP, continuing at BOTTOM" messages are only --- indicated by a "W" (Mnemonic: Wrapped) letter before the --- search count statistics. The maximum limit can be set with ---- the 'maxsearchcount' option. +--- the 'maxsearchcount' option, see also `searchcount()` +--- function. --- --- This gives you the opportunity to avoid that a change between buffers --- requires you to hit , but still gives as useful a message as diff --git a/runtime/syntax/make.vim b/runtime/syntax/make.vim index 338150fa94..8af09954be 100644 --- a/runtime/syntax/make.vim +++ b/runtime/syntax/make.vim @@ -7,6 +7,8 @@ " 2025 Apr 15 by Vim project: rework Make flavor detection (#17089) " 2025 Oct 12 by Vim project: update makeDefine highlighting (#18403) " 2025 Oct 25 by Vim project: update makeTargetinDefine highlighting (#18570) +" 2025 Dec 23 by Vim project: fix too greedy match (#18938) +" 2025 Dec 23 by Vim project: wrong highlight with paranthesis inside quotes (#18818) " quit when a syntax file was already loaded if exists("b:current_syntax") @@ -40,21 +42,21 @@ syn match makeIdent "\$\$\w*" syn match makeIdent "\$\$\$\$\w*" containedin=makeDefine syn match makeIdent "\$[^({]" syn match makeIdent "\$\$[^({]" containedin=makeDefine +if get(b:, 'make_flavor', s:make_flavor) == 'microsoft' + syn region makeIdent start="\$(" end=")" contains=makeStatement,makeIdent,makeDString,makeSString + syn region makeIdent start="\${" end="}" contains=makeStatement,makeIdent,makeDString,makeSString + syn region makeIdent start="\$\$(" end=")" containedin=makeDefine contains=makeStatement,makeIdent,makeDString,makeSString + syn region makeIdent start="\$\${" end="}" containedin=makeDefine contains=makeStatement,makeIdent,makeDString,makeSString +else + syn region makeIdent start="\$(" skip="\\)\|\\\\" end=")" contains=makeStatement,makeIdent,makeDString,makeSString + syn region makeIdent start="\${" skip="\\}\|\\\\" end="}" contains=makeStatement,makeIdent,makeDString,makeSString + syn region makeIdent start="\$\$(" skip="\\)\|\\\\" end=")" containedin=makeDefine contains=makeStatement,makeIdent,makeDString,makeSString + syn region makeIdent start="\$\${" skip="\\}\|\\\\" end="}" containedin=makeDefine contains=makeStatement,makeIdent,makeDString,makeSString +endif syn match makeIdent "^ *[^:#= \t]*\s*[:+?!*]="me=e-2 syn match makeIdent "^ *[^:#= \t]*\s*::="me=e-3 syn match makeIdent "^ *[^:#= \t]*\s*="me=e-1 syn match makeIdent "%" -if get(b:, 'make_flavor', s:make_flavor) == 'microsoft' - syn region makeIdent start="\$(" end=")" contains=makeStatement,makeIdent - syn region makeIdent start="\${" end="}" contains=makeStatement,makeIdent - syn region makeIdent start="\$\$(" end=")" containedin=makeDefine contains=makeStatement,makeIdent - syn region makeIdent start="\$\${" end="}" containedin=makeDefine contains=makeStatement,makeIdent -else - syn region makeIdent start="\$(" skip="\\)\|\\\\" end=")" contains=makeStatement,makeIdent - syn region makeIdent start="\${" skip="\\}\|\\\\" end="}" contains=makeStatement,makeIdent - syn region makeIdent start="\$\$(" skip="\\)\|\\\\" end=")" containedin=makeDefine contains=makeStatement,makeIdent - syn region makeIdent start="\$\${" skip="\\}\|\\\\" end="}" containedin=makeDefine contains=makeStatement,makeIdent -endif " Makefile.in variables syn match makeConfig "@[A-Za-z0-9_]\+@" diff --git a/src/nvim/options.lua b/src/nvim/options.lua index 9452aec4be..0ec045e535 100644 --- a/src/nvim/options.lua +++ b/src/nvim/options.lua @@ -5713,7 +5713,8 @@ local options = { When the number of matches exceeds this value, Vim shows ">" instead of the exact count to keep searching fast. Note: larger values may impact performance. - The value must be between 1 and 9999. + The value must be between 1 and 9999. See also the |searchcount()| + function. ]=], full_name = 'maxsearchcount', scope = { 'global' }, @@ -7981,7 +7982,8 @@ local options = { "search hit TOP, continuing at BOTTOM" messages are only indicated by a "W" (Mnemonic: Wrapped) letter before the search count statistics. The maximum limit can be set with - the 'maxsearchcount' option. + the 'maxsearchcount' option, see also |searchcount()| + function. This gives you the opportunity to avoid that a change between buffers requires you to hit , but still gives as useful a message as