1
0
Fork 0
mirror of https://github.com/vim/vim synced 2025-03-26 19:55:11 +01:00
Commit graph

20744 commits

Author SHA1 Message Date
zeertzjq
3a0cc36c69
patch 9.1.1011: popupmenu internal error with some abbr in completion item
Problem:  Popup menu internal error with some abbr in completion item.
Solution: Don't compute attributes when there is no corresponding text.
          Reduce indent in pum_redraw() while at it (zeertzjq).

fixes: 
closes: 

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-13 07:27:43 +01:00
Konfekt
c200f53cbb
patch 9.1.1010: filetype: VisualCode setting file not recognized
Problem:  filetype: VisualCode setting file not recognized
Solution: detect json files in VSCode config directory as jsonc filetype
          (Konfekt)

closes: 

Signed-off-by: Konfekt <Konfekt@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-12 20:02:04 +01:00
Jonathon
7c7a4e6d1a
patch 9.1.1009: diff feature can be improved
Problem:  diff feature can be improved
Solution: include the linematch diff alignment algorithm
          (Jonathon)

closes: 

Signed-off-by: Jonathon <jonathonwhite@protonmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-12 09:58:00 +01:00
zeertzjq
faf250c9e4
patch 9.1.1008: tests: test for patch 9.1.1006 doesn't fail without the patch
Problem:  tests: test for patch 9.1.1006 doesn't fail without the patch
          (after v9.1.1006)
Solution: Add ctermbg=NONE to the highlight groups (zeertzjq).

closes: 

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-12 09:32:27 +01:00
Wu, Zhenyu
8cbe2e0a0a
patch 9.1.1007: filetype: various ignore are not recognized
Problem:  filetype: various ignore are not recognized
Solution: detect rg/docker/npm/vvsce ignore files as 'gitgnore' filetype
          (Wu, Zhenyu)

Not only prettier, but many programs also support ignore files (like rg,
docker, npm, vscode). So use the gitignore filetype for them due to same syntax

closes: 

Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-12 09:27:01 +01:00
Aliaksei Budavei
5eaacef18e
tests: Load screendump files with "git vimdumps"
Also, fold the difference part and the bottom part for the
identical screendump files.

closes: 

Co-authored-by: D. Ben Knoble <ben.knoble+github@gmail.com>
Signed-off-by: Aliaksei Budavei <0x000c70@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-11 17:12:04 +01:00
glepnir
9eff3ee818
patch 9.1.1006: PmenuMatch completion highlight can be combined
Problem:  PmenuMatch completion highlight can be combined
Solution: Combine highlight groups PmenuMatch with Pmenu and
          PmenuMatchSel with PmenuSel (glepnir)

fixes: 
closes: 

Signed-off-by: glepnir <glephunter@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-11 16:47:34 +01:00
glepnir
9fddb8ae77
patch 9.1.1005: completion text is highlighted even with no pattern found
Problem:  completion text is highlighted even with no pattern found
Solution: use ins_compl_leader_len() instead of checking
          compl_leader.length (glepnir)

closes: 

Signed-off-by: glepnir <glephunter@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-11 16:42:50 +01:00
Christian Brabandt
ebb08d5913
patch 9.1.1004: tests: a few termdebug tests are flaky
Problem:  tests: a few termdebug tests are flaky; test_termdebug_basic()
          and test_termdebug_config_types() may fail if there is too
          much load
Solution: Set g:test_is_flaky

Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-11 15:43:12 +01:00
Christian Brabandt
c9a1e257f1
patch 9.1.1003: [security]: heap-buffer-overflow with visual mode
Problem:  [security]: heap-buffer-overflow with visual mode when
          using :all, causing Vim trying to access beyond end-of-line
          (gandalf)
Solution: Reset visual mode on :all, validate position in gchar_pos()
          and charwise_block_prep()

This fixes CVE-2025-22134

Github Advisory:
https://github.com/vim/vim/security/advisories/GHSA-5rgf-26wj-48v8

Co-authored-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-11 15:25:00 +01:00
Christian Brabandt
9598a6369b
runtime(doc): add package-<name> helptags for included packages
Improve how to find the justify package

closes: 

Co-authored-by: Peter Benjamin <petermbenjamin@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-11 10:14:24 +01:00
Yegappan Lakshmanan
c10342da44
patch 9.1.1002: Vim9: unknown func error with interface declaring func var
Problem:  Vim9: unknown function error with interface declaring a
          function variable (lifepillar)
Solution: Use correct instruction for getting interface member variables
          (Yegappan Lakshmanan)

fixes: 
closes: 

Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-11 09:39:01 +01:00
Christian Brabandt
668e9f2403
runtime(filetype): don't detect string interpolation as angular
fixes: 

Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-11 09:20:55 +01:00
glepnir
ad409876d9
patch 9.1.1001: ComplMatchIns highlight hard to read on light background
Problem:  ComplMatchIns highlight hard to read on light background
          (after v9.1.0996)
Solution: define the highlighting group cleared, it should be configured in
          colorschemes separately (glepnir)

closes: 

Signed-off-by: glepnir <glephunter@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-10 20:08:20 +01:00
Doug Kearns
695522dea3
runtime(vim): Update base-syntax, highlight literal string quote escape
Match the '' escape sequence in literal strings.  These were previously
ending the current string and starting another concatenated literal
string.

closes: 

Signed-off-by: Christian Brabandt <cb@256bit.org>
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
2025-01-10 20:02:17 +01:00
Yochem van Rosmalen
51754c8a49
runtime(editorconfig): set omnifunc to syntaxcomplete func
closes: 

Signed-off-by: Yochem van Rosmalen <git@yochem.nl>
Signed-off-by: Riley Bruins <ribru17@hotmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-10 19:54:13 +01:00
Yee Cheng Chin
ebea31e454
patch 9.1.1000: tests: ruby tests fail with Ruby 3.4
Problem:  tests: ruby tests fail with Ruby 3.4
Solution: adjust expected output for Ruby 3.4
          (Yee Cheng Chin)

Vim's Ruby tests relied on explicit matching of output texts which are
fragile in design. Ruby 3.4 has changed the output slightly (using
'name' instead of `name', and also using more spaces in dictionary
printouts). Modify the Vim tests to be less fragile to such changes.

closes: 

Signed-off-by: Yee Cheng Chin <ychin.git@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-09 22:23:29 +01:00
Yee Cheng Chin
2051af1642
patch 9.1.0999: Vim9: leaking finished exception
Problem:  leaking finished exception
          (after v9.1.0984)
Solution: use finish_exception to clean up caught exceptions
          (Yee Cheng Chin)

In Vimscript, v:exception/throwpoint/stacktrace are supposed to reflect
the currently caught exception, and be popped after the exception is
finished (via endtry, finally, or a thrown exception inside catch).
Vim9script does not handle this properly, and leaks them instead. This
is clearly visible when launching GVim with menu enabled.  A caught
exception inside the s:BMShow() in menu.vim would show up when querying
`v:stacktrace` even though the exception was already caught and handled.

To fix this, just use the same functionality as Vimscript by calling
`finish_exception` to properly restore the states. Note that this
assumes `current_exception` is always the same as `caught_stack` which
believe should be the case.

Added tests for this. Also fix up test_stacktrace to properly test the
stack restore behavior where we have nested exceptions in catch blocks
and to also test the vim9script functionality properly.

- Also, remove its dependency on explicitly checking a line number in
  runtest.vim which is a very fragile way to write tests as any minor
  change in runtest.vim (shared among all tests) would require changing
  test_stacktrace.vim. We don't actually need such granularity in the
  test.

closes: 

Signed-off-by: Yee Cheng Chin <ychin.git@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-09 22:14:34 +01:00
Wu, Zhenyu
df4a7d7617
runtime(tiasm): use correct syntax name tiasm in syntax script
closes: 

Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-09 22:09:16 +01:00
Wu, Zhenyu
4f73c07abf
patch 9.1.0998: filetype: TI assembly files are not recognized
Problem:  filetype: TI assembly files are not recognized
Solution: inspect '*.sa' and assembly files and detect TI assembly
          files, include filetype plugin and syntax script for TI
          assembly files (Wu, Zhenyu)

closes: 

Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-08 20:26:38 +01:00
John Marriott
a21240b97d
patch 9.1.0997: too many strlen() calls in drawscreen.c
Problem:  too many strlen() calls in drawscreen.c
Solution: refactor drawscreen.c and remove calls to strlen(),
          make get_keymap_str() (in screen.c) return string length
          instead of TRUE/FALSE (John Marriott).

Signed-off-by: John Marriott <basilisk@internode.on.net>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-08 20:10:59 +01:00
Jan-Arvid Harrach
8ab1819df6
runtime(xf86conf): add section name OutputClass to syntax script
References:
https://man.archlinux.org/man/xorg.conf.5#DESCRIPTION

closes: 

Signed-off-by: Jan-Arvid Harrach <jharrach@tutanota.com>
2025-01-08 20:05:05 +01:00
glepnir
e890887b80
patch 9.1.0996: ComplMatchIns may highlight wrong text
Problem:  ComplMatchIns may highlight wrong text
Solution: don't highlight in case of fuzzy match,
          skip-highlight when not inserting anything
          (glepnir)

closes: 

Signed-off-by: glepnir <glephunter@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-08 18:30:45 +01:00
Doug Kearns
1718e7d07e
runtime(vim): Update base-syntax, improve ex-bang matching
Always match ex-bang explicitly rather than incidentally as the ! operator.

fixes: 
closes: 

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-08 18:20:47 +01:00
Christian Brabandt
1f045f324d
runtime(doc): clarify buffer deletion on popup_close()
Reported-by: Lifepillar <lifepillar@lifepillar.me>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-08 14:09:02 +01:00
Philip H.
e0424b3348
CI: drop setup of snd-dummy module
Apparently even when loading the snd-dummy kernel module, the
CI tests for the sounds feature in test_sound.vim are already skipped.

So let's just remove all of this (even so we may loose a bit of coverage
information here).

closes: 

Signed-off-by: Philip H. <47042125+pheiduck@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-07 20:43:29 +01:00
mtvare6
616219f684
patch 9.1.0995: filetype: shaderslang files are not detected
Problem:  filetype: shaderslang files are not detected
Solution: detect '*.slang' files as shaderslang filetype,
          include a filetype and syntax script (mtvare6)

Reference:
https://shader-slang.com/

closes: 

Signed-off-by: mtvare6 <mtvare6@proton.me>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-07 20:31:27 +01:00
Yegappan Lakshmanan
0072ceedc6
patch 9.1.0994: Vim9: not able to use comment after opening curly brace
Problem:  Vim9: not able to use comment after opening curly brace
          (lifepillar)
Solution: allow to use comments after curly braces of an inner-block,
          modify the logic to search for comment in a line, update Vim9
          tests to use specific class type instead of any
          (Yegappan Lakshmanan)

fixes: 
closes: 

Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-07 20:22:32 +01:00
Luuk van Baal
c97e869535
patch 9.1.0993: New 'cmdheight' behavior may be surprising
Problem:  Although patch 9.1.0990 fixed a real problem/inconsistency,
          it also introduced new behavior that may break BWC and/or be
          unexpected. Before 9.1.0990, window commands could make the
          topframe smaller (without changing 'cmdheight'; quirk that is
          now fixed), but did not allow extending the topframe beyond
          the 'cmdheight' set by the user. After 9.1.0990, the user can
          reduce the 'cmdheight' below the value they set explicitly,
          through window commands, which may lead to confusion.
          (aftere v9.1.0990)
Solution: Store the value explicitly set by the user and clamp the
          'cmdheight' when resizing the topframe. This also applies to
          dragging laststatus, which in contrast to window commands
          _did_ allow reducing the 'cmdheight' to values below the one
          set by the user. So with this patch there is still new
          behavior, but I think in a way that is less surprising.
          While at it, also fix a Coverity warning, introduced in
          v9.1.0990 (Luuk van Baal)

closes: 

Signed-off-by: Luuk van Baal <luukvbaal@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-06 18:58:21 +01:00
Christian Brabandt
3159b6494e
runtime(sh): fix typo in Last Change header
related: 

Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-06 18:50:15 +01:00
Yegappan Lakshmanan
2050dcc20f
patch 9.1.0992: Vim9: double-free after v9.1.0988
Problem:  Vim9: double-free after v9.1.0988
          (h-east)
Solution: clear typval pointer, before setting the type
          (Yegappan Lakshmanan)

Otherwise the contents are still referring to some other value.

fixes: 
closes: 

Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-06 18:34:49 +01:00
zeertzjq
6655bef330
patch 9.1.0991: v:stacktrace has wrong type in Vim9 script
Problem:  v:stacktrace has wrong type in Vim9 script.
Solution: Change the type to t_list_dict_any.  Fix grammar in docs.
          (zeertzjq)

closes: 

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-06 18:32:13 +01:00
Jon Parise
cf1f55548d
runtime(sh): add PS0 to bashSpecialVariables in syntax script
PS0 is also a special prompt variable. (It is expanded and displayed
after it reads a command but before executing it.)

References:
https://www.gnu.org/software/bash/manual/html_node/Interactive-Shell-Behavior.html

closes: 

Signed-off-by: Jon Parise <jon@indelible.org>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-06 18:27:38 +01:00
Doug Kearns
7ceaa8f3dd
runtime(vim): Remove trailing comma from match_words
fixes:  (`filetype plugin indent on` breaks matchit).
closes: 

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-06 18:12:11 +01:00
Christian Brabandt
202ebc6ced
runtime(zsh): sync syntax script with upstream repo
fixes: 

Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-05 16:36:40 +01:00
Doug Kearns
8a27d97848
runtime(doc): Capitalise the mnemonic "Zero" for the 'z' flag of search()
closes: 

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-05 15:56:57 +01:00
Luuk van Baal
e15cbc1af4
patch 9.1.0990: Inconsistent behavior when changing cmdheight
Problem:  Inconsistent behavior when changing cmdheight by resizing the
          topframe through wincmds and dragging laststatus. Changing
	  cmdheight by resizing the topframe does not trigger OptionSet.
Solution: Consolidate logic for changing the cmdheight, set the option
	  value to handle side-effects (Luuk van Baal)

closes: 

Signed-off-by: Luuk van Baal <luukvbaal@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-04 17:18:08 +01:00
Doug Kearns
dbe39edb29
patch 9.1.0989: Vim9: Whitespace after the final enum value causes a syntax error
Problem:  Vim9: Whitespace after the final enum value causes a syntax
          error
Solution: Fix parsing to allow whitespace after the final enum value.
          (Doug Kearns)

closes: 

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-04 17:12:24 +01:00
Aliaksei Budavei
cd96075cde
runtime(java): Quietly opt out for unsupported markdown.vim versions
fixes 
closes: 

Signed-off-by: Aliaksei Budavei <32549825+zzzyxwvut@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-03 17:38:14 +01:00
h-east
6139766e82
runtime(vim): fix failing vim syntax test
after v9.1.0985

related: 

Signed-off-by: h-east <h.east.727@gmail.com>
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-03 17:32:54 +01:00
Yegappan Lakshmanan
b04af4cc96
patch 9.1.0988: Vim9: no error when using uninitialized var in new()
Problem:  Vim9: no error when using uninitialized var in new()
          (lifepillar, Aliaksei Budavei)
Solution: Give an error if an uninitialized object variable is referenced
          in new() (Yegappan Lakshmanan)

fixes: 
fixes: 
closes: 

Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-03 10:50:08 +01:00
h-east
27f2e473e1
runtime(doc): update index.txt
related: 
closes: 

Signed-off-by: h-east <h.east.727@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-03 10:45:15 +01:00
Zoe Roux
a407573f30
patch 9.1.0987: filetype: cake files are not recognized
Problem:  filetype: cake files are not recognized
Solution: detect '*.cake' files as cs filetype
          (Zoe Roux)

References:
https://cakebuild.net/

closes: 

Signed-off-by: Zoe Roux <zoe.roux@zoriya.dev>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-03 10:40:31 +01:00
Gregory Anders
58c44e8833
patch 9.1.0986: filetype: 'jj' filetype is a bit imprecise
Problem:  filetype: 'jj' filetype is a bit imprecise
Solution: rename 'jj' filetype to 'jjdescription'
          (Gregory Anders)

closes: 

Signed-off-by: Gregory Anders <greg@gpanders.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-03 10:35:35 +01:00
Gregory Anders
bde76da4d0
runtime(jj): Support diffs in jj syntax
related: 

Signed-off-by: Gregory Anders <greg@gpanders.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-03 10:34:24 +01:00
Doug Kearns
fc61cfd60e
runtime(vim): Update matchit pattern, no Vim9 short names
Abbreviated :enum and :interface commands are no longer supported.

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-03 10:28:09 +01:00
h-east
aa979c763d
patch 9.1.0985: Vim9: some ex commands can be shortened
Problem:  Vim9: some ex commands can be shortened
Solution: disallow shortening of :abstract, :interface and :type
          (h-east)

closes: 

Signed-off-by: h-east <h.east.727@gmail.com>
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-03 10:19:45 +01:00
ichizok
663d18d610
patch 9.1.0984: exception handling can be improved
Problem:  exception handling can be improved
Solution: add v:stacktrace and getstacktrace()

closes: 

Co-authored-by: Naruhiko Nishino <naru123456789@gmail.com>
Signed-off-by: ichizok <gclient.gaap@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-02 18:06:00 +01:00
h-east
fd771613b3
runtime(doc): update doc for :horizontal
Revert the documentation for :horizontal from commit
0c3e57b403 because :horizontal cannot be shortened to :ho

closes: 

Signed-off-by: h-east <h.east.727@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-02 17:34:55 +01:00
h-east
0c3e57b403
runtime(doc): update index.txt, windows.txt and version9.txt
closes: 

Co-authored-by: Aliaksei Budavei <32549825+zzzyxwvut@users.noreply.github.com>
Signed-off-by: h-east <h.east.727@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-01-02 11:00:49 +01:00