Commit Graph

9570 Commits

Author SHA1 Message Date
zeertzjq
8db42b3b86 vim-patch:bfcf638: runtime(java): Make changes for JDK 25 (#36017)
- Add to the list of java.lang classes three new types: IO,
  ScopedValue, and ScopedValue.Carrier.
- Add to the list of java.lang interfaces a new type:
  ScopedValue.CallableOp.
- "Demote" RuntimePermission from the list of java.lang
  class types to javaLangDeprecated.
- Reintroduce supported syntax-preview-feature numbers 455
  and 488 as _a new number_ 507.

References:
https://bugs.openjdk.org/browse/JDK-8353641
https://openjdk.org/jeps/506 (Scoped Values)
https://openjdk.org/jeps/507 (Primitive Types in Patterns etc.)
https://openjdk.org/jeps/512 (Compact Source Files etc.)

closes: vim/vim#18479

bfcf638c73

Co-authored-by: Aliaksei Budavei <0x000c70@gmail.com>
2025-10-04 19:15:48 +08:00
zeertzjq
b6b80824cc vim-patch:9.1.1819: Cannot configure the inner foldlevel indicator (#36010)
Problem:  Cannot configure the inner foldlevel indicator for the
          foldcolumn
Solution: Add "foldinner" suboption value to the 'fillchar' option
          (Maria José Solano).

closes: vim/vim#18365

1a691afd27

Co-authored-by: Maria José Solano <majosolano99@gmail.com>
2025-10-03 23:53:29 +00:00
zeertzjq
2c76a50e20 vim-patch:9.1.1821: filetype: Not all PKL files are recognized (#36008)
Problem:  filetype: Not all PKL files are recognized
Solution: Detect *.pcf as pkl filetype, detect using the pkl-lsp://
          protocol as pkl filetype, include PKL syntax script
          (Jan Claußen)

This adds basic syntax support for the new PKL language by Apple.

What works:
- Shebang support
- Comment support
- Integers (decimal, hex, octal and binary) support
- Floating point support including exponentials
- Basic datatype support
- Unicode escape delimiters
- Escape code support
- String interpolation
- Support up to five pounds for custom delimiters
- Folding of multi-line comments and blocks

What doesn't work:

  The language heavily uses parameterized type declarations, which can get
  very complex. It is very hard to highlight this properly. There is
  official Tree-sitter support for this. Since it is hard to pull this off
  in a vim syntax file, I opted for basic support of the data types.

References:
  https://github.com/apple/pkl-pantry

fixes: vim/vim#18271
closes: vim/vim#18274

67a8f2945e

Co-authored-by: Jan Claußen <jan.claussen10@web.de>
2025-10-04 06:01:16 +08:00
zeertzjq
0124481c80 vim-patch:0a8b4ef: runtime(log): remove domain highlight (#36002)
The domain highlight is eazy to be confused and useless. Because we can
catch URL as a much obvious syntax.

closes: vim/vim#18467

0a8b4ef8b2

Co-authored-by: Mao-Yining <mao.yining@outlook.com>
2025-10-03 17:30:40 +08:00
zeertzjq
1939ec1763 vim-patch:09b1ce0: runtime(doc): fix typo after commit cfcf1a57cbef (#36001)
related: vim/vim#18452

09b1ce0860

Co-authored-by: Christian Brabandt <cb@256bit.org>
2025-10-03 17:30:24 +08:00
zeertzjq
e4d8474ad9 vim-patch:12da242: runtime(new-tutor): fix mismatched line numbers in vim-02-beginner
closes: vim/vim#18466

12da2427c7
2025-10-03 16:16:52 +08:00
zeertzjq
c755172a34 vim-patch:9d57fe2: runtime(new-tutor): Updated English new tutor
This updates the new tutor with the changes from commit
b87f133b0724f7328e7dd41dd611af67f4ae3e39

closes: vim/vim#18461

9d57fe278f

Link to :checkhealth for clipboard support.

Co-authored-by: RestorerZ <restorer@mail2k.ru>
2025-10-03 16:16:26 +08:00
Yi Ming
18d6436ad2 fix(lsp): inlineCompletion: ignore out-of-range items #35990 2025-10-02 16:00:39 -07:00
Riley Bruins
ac15b384a6 refactor(treesitter): use scratch buffer for string parser #35988
This commit changes `languagetree.lua` so that it creates a scratch
buffer under the hood when dealing with string parsers. This will make
it much easier to just use extmarks whenever we need to track injection
trees in `languagetree.lua`. This also allows us to remove the
`treesitter.c` code for parsing a string directly.

Note that the string parser's scratch buffer has `set noeol nofixeol` so
that the parsed source exactly matches the passed in string.
2025-10-02 15:33:18 -07:00
Gregory Anders
8eb0964537 feat(tui): native progress bars for Progress events #35973 2025-10-02 14:51:26 -07:00
zeertzjq
9f33b69cfd vim-patch:cfcf1a5: runtime(doc): Clarify use of "noselect" in 'completeopt'
closes: vim/vim#18452

cfcf1a57cb

Co-authored-by: Girish Palya <girishji@gmail.com>
Co-authored-by: Tomasz N <przepompownia@users.noreply.github.com>
2025-10-02 11:40:36 +08:00
zeertzjq
3f422cb5eb vim-patch:6e28211: runtime(doc): Tweak documentation style
closes: vim/vim#18462

6e282117c7

Co-authored-by: Hirohito Higashi <h.east.727@gmail.com>
2025-10-02 11:40:36 +08:00
Sergei Slipchenko
a1bc5d0ae6 fix(diagnostics): showing stale diagnostics in handlers #35890
Fixes #35884

Problem: Since `once_buf_loaded` might call a callback passed to it at a
later point (which is it's reason to exist) that callback might end up
referring to stale diagnostics in a handler's `show` function. For
example, if we first call `vim.diagnostic.set` for an unloaded buffer,
then call `vim.diagnostic.reset` and only then load the buffer, we might
still see diagnostics from `vim.diagnostic.set` call, which are stale at
this point.

Solution: only keep one autocommand from the most reset `show` call and
delete it when `hide` is called.
2025-10-01 20:17:55 -07:00
zeertzjq
d72c805e87 vim-patch:8337d77: runtime(netrw): MS-Windows: fix netrw not being able to navigate to parent folder (#35982)
fixes: vim/vim#18421
closes: vim/vim#18464

8337d77eff

Co-authored-by: Miguel Barro <miguel.barro@live.com>
2025-10-02 01:57:53 +00:00
zeertzjq
c12efc50a9 vim-patch:a644b79: runtime(optwin): Update formatting of option descriptions (#35980)
closes: vim/vim#18446

a644b7924d

Co-authored-by: RestorerZ <restorer@mail2k.ru>
2025-10-02 09:06:41 +08:00
zeertzjq
39c0425c4c vim-patch:0977c8b: runtime(vim): Update base syntax, contain user command replacement text (#35979)
Ensure that :command replacement text terminates at the end of the
logical line.

Add :command to the generator exclusion list.

fixes: vim/vim#18414 (@Dougaak)
fixes: vim/vim#18448 (Maxim Kim)
closes: vim/vim#18415

0977c8b03e

Co-authored-by: Doug Kearns <dougkearns@gmail.com>
2025-10-02 00:41:04 +00:00
zeertzjq
43f7434bd5 vim-patch:014c731: runtime(doc): make :h virtcol() more accurate (#35976)
The current description (especially the "unlimited width" part) is
inaccurate in several ways:
- The size of virtual text can depend on window width. In particular,
  the size of "above" virtual text can be equal to window width.
- A double-width character that doesn't fit adds 1 to the virtual column
  of the following characters.
- The size of 'showbreak' and 'breakindent' is counted.

related: vim/vim#5713
closes: vim/vim#18447

014c731fa5
2025-10-01 23:33:36 +00:00
v1nh1shungry
70460d557c fix(lsp): scope inline_completion autocmds to buffer (#35965)
Problem:
Autocmds in inline_completion Completor are not scoped to specific
buffers. When multiple buffers have inline completion enabled, events
(InsertEnter, CursorMovedI, TextChangedP, InsertLeave) in any buffer
trigger callbacks for all Completor instances, causing incorrect
behavior across buffers.

Solution:
Add `buffer = bufnr` parameter to nvim_create_autocmd() calls to make
them buffer-local. Each Completor instance now only responds to events
in its own buffer.
2025-10-01 06:56:56 -07:00
zeertzjq
e6b2255ac7 vim-patch:4edaf89: runtime(doc): improve preinserted() doc
Change the second "if" to "because", otherwise it may be misinterpreted
that preinserted() can return non-zero just because these options are
set.

closes: vim/vim#18409

4edaf89233
2025-09-30 09:32:33 +08:00
zeertzjq
7b9c063d11 vim-patch:9.1.1797: completion: autocompletion can be improved
Problem:  completion: autocompletion can be improved
Solution: Add support for "longest" and "preinsert" in 'autocomplete';
          add preinserted() (Girish Palya)

* Add support for "longest" in 'completeopt' when 'autocomplete'
  is enabled. (Note: the cursor position does not change automatically
  when 'autocomplete' is enabled.)
* Add support for "preinsert" when 'autocomplete' is enabled. Ensure
  "preinsert" works the same with and without 'autocomplete'
* introduce the preinserted() Vim script function, useful for defining
  custom key mappings.

fixes: vim/vim#18314
closes: vim/vim#18387

c05335082a

Co-authored-by: Girish Palya <girishji@gmail.com>
2025-09-30 09:32:33 +08:00
zeertzjq
4896178863 vim-patch:05e44e9: runtime(tex): add amsmath support to tex syntax script (#35958)
Problem:  tex syntax file does not support some of the math equation
          environments provided by amsmath.sty, therefore well-formed
          snippet is highlighted as "texBadMath"
Solution: add the environments

closes: vim/vim#18433

05e44e978f

Co-authored-by: Eisuke Kawashima <e-kwsm@users.noreply.github.com>
2025-09-30 08:26:55 +08:00
zeertzjq
af2932e2dc vim-patch:992e307: runtime(doc): update list of modifiers at :h expand() (#35957)
fixes: vim/vim#18435

992e30774f

Co-authored-by: Christian Brabandt <cb@256bit.org>
2025-09-30 08:26:40 +08:00
Maria Solano
9da316fcc4 fix(docs): force blank line after numbered list items #35950
Workaround until the vimdoc parser supports numbered list-items:
https://github.com/neovim/tree-sitter-vimdoc/issues/144
2025-09-28 21:01:20 -07:00
Justin M. Keyes
2739ab485e docs: json, tests, lsp #35754
Close #35926
Close #35818

Co-authored-by: skewb1k <skewb1kunix@gmail.com>
Co-authored-by: glepnir <glephunter@gmail.com>
2025-09-28 20:57:59 -07:00
zeertzjq
11b6fcdfa6 vim-patch:ae20d73: runtime(vim): Update base syntax, improve line-continuation skip patterns
Factor out the common prefix in line-continuation :syn-skip patterns.

closes: vim/vim#18416

ae20d732ae

Co-authored-by: Doug Kearns <dougkearns@gmail.com>
2025-09-29 09:23:42 +08:00
zeertzjq
7c9a4a2a71 vim-patch:f4a6acd: runtime(vim): Update base syntax, allow Vim9 :echo tail comments
- Match comments after Vim9 :echo and :execute.
- Match comments after Vim9 and legacy :eval.

closes: vim/vim#18420

f4a6acd86e

Co-authored-by: Doug Kearns <dougkearns@gmail.com>
2025-09-29 09:19:07 +08:00
zeertzjq
2cd899f730 vim-patch:7bb733f: runtime(vim): Update base syntax, match null_tuple literal
closes: vim/vim#18404

7bb733f6bf

Co-authored-by: Doug Kearns <dougkearns@gmail.com>
2025-09-29 09:17:13 +08:00
zeertzjq
e9d8d1b061 vim-patch:57d243e: runtime(vim): Update base syntax, fix indented Vim9 :redir highlighting
Include post operator whitespace in the Vim9 variable assignment
lookahead so that "redir =>" doesn't match as an assignment.

fixes: vim/vim#18319
closes: vim/vim#18323

57d243e27d

Co-authored-by: Doug Kearns <dougkearns@gmail.com>
2025-09-29 09:16:50 +08:00
zeertzjq
6b0365ae2f vim-patch:6f97624: runtime(vim): Update base syntax, fix Vim9 :for loop variable highlighting
Highlight the iteration variable's type in Vim9 :for {var} loops.

Reported by Aliaksei Budavei.

fixes: vim/vim#17961
closes: vim/vim#18163

6f97624e11

Co-authored-by: Doug Kearns <dougkearns@gmail.com>
2025-09-29 09:16:17 +08:00
zeertzjq
0ebb2ec4e4 vim-patch:4de931d: runtime(vim): Update base syntax, match enum constructor type args
closes: vim/vim#17840

4de931daae

Co-authored-by: Doug Kearns <dougkearns@gmail.com>
Co-authored-by: Aliaksei Budavei <0x000c70@gmail.com>
2025-09-29 09:15:17 +08:00
zeertzjq
22f6b9d11f vim-patch:72473ce: runtime(vim): Update base syntax, match generic functions
Match Vim9 generic functions, added in vim/vim#17313.

closes: vim/vim#17722

72473ce9f8

Co-authored-by: Doug Kearns <dougkearns@gmail.com>
2025-09-29 09:14:39 +08:00
zeertzjq
c07a24e31c vim-patch:91ac18c: runtime(java): Recognise _module_ import declarations (#35947)
After two preview proposals (JEPs 476 and 494), _module_
import declarations are now a part of the language (JDK 25).

Reference:
https://openjdk.org/jeps/511

closes: vim/vim#18424

91ac18cb03

Co-authored-by: Aliaksei Budavei <0x000c70@gmail.com>
2025-09-29 01:03:42 +00:00
zeertzjq
0fa0717d4e vim-patch:9.1.1802: 'nowrap' in a modeline may hide malicious code (#35946)
Problem:  'nowrap' in a modeline may hide malicious code.
Solution: Forcibly use '>' as 'listchars' "extends" if 'nowrap' was set
          from a modeline (zeertzjq).

Manual `:setlocal nowrap` disables this behavior.  There is a separate
problem with `:set nowrap` that also applies to some other options.

related: vim/vim#18214
related: vim/vim#18399
closes: vim/vim#18425

9d5208a931

Cherry-pick some test_modeline.vim changes from patches 9.0.{0363,0626}.
2025-09-29 07:48:46 +08:00
glepnir
fcf752476a fix(cmd): :update writes new file buffers only for real files #35939
Problem: :update should write new file buffers, but previous fix
affected special buffer types (acwrite, nofile, etc.).

Solution: Add bt_nofilename() check to only write new files for
buffers representing real filesystem paths.
2025-09-27 20:28:05 -07:00
Maria Solano
03032d1f73 fix(lsp): remove vim.lsp.diagnostic.reset() (#35938) 2025-09-27 14:53:00 -07:00
Maria Solano
c5c6ddba91 feat(lsp): document method types (#35934) 2025-09-27 14:52:30 -07:00
Maria Solano
5fbc5ab810 fix(lsp): use correct workspace.diagnostics capability key (#35937) 2025-09-27 13:40:52 -07:00
Eisuke Kawashima
2d8ed73143 build(vim-patch.sh): ignore runtime/*/testdir/
tracked files are removed
2025-09-27 18:55:43 +08:00
skewb1k
e3c36f31e3 fix(highlight): ensure extmark range is within buffer bounds #35928
Adds an additional check for the case when end_col = 0, addressing
https://github.com/neovim/neovim/issues/35814#issuecomment-3340709532.

Validation is now localized to the highlighter without affecting the C API.
2025-09-26 19:32:28 -07:00
Tomasz N
56709ca168 fix(extui): setup buffers after activating eventignorewin (#35915)
fix(extui): set options and buffer name after 'eventignorewin'

Problem:  Setting up extui buffers emits OptionSet and BufFilePost events.
Solution: Set options and buffer name after 'eventignorewin'.
2025-09-26 01:51:14 +00:00
zeertzjq
a9486fe7e1 vim-patch:900c747: runtime(python): fix 'type' syntax highlighting (#35918)
The previous patterns unintentionally highlighted words like 'typename'.

addresses: https://github.com/vim/vim/pull/18090#issuecomment-3333025523
closes: vim/vim#18394

900c747da3

Co-authored-by: Jon Parise <jon@indelible.org>
2025-09-26 07:54:19 +08:00
zeertzjq
0646d0ea28 vim-patch:b6f9d38: runtime(doc): Improve documentation of the ..= assignment operator (#35916)
Explicitly mention the "..=" compound assignment operator everywhere
".=" is documented.

Convert some uses of "." and ".=" in the examples to ".." and "..=",
respectively.

closes: vim/vim#18380

b6f9d38f96

Cherry-pick a change to eval.txt from patch 9.1.1232.

Co-authored-by: Doug Kearns <dougkearns@gmail.com>
2025-09-25 23:31:21 +00:00
zeertzjq
0be3dee44f vim-patch:4b97fc9: runtime(javascript): Add "using" keyword to JavaScript syntax highlighting (#35910)
Prior to this change, const and let were keywords for variable
declarations.

This change adds `using` as another keyword for variable declaration.

This JavaScript feature was recently introduced.

Docs:
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/using

closes: vim/vim#18381

4b97fc901f

Co-authored-by: Devin Weaver <suki@tritarget.org>
2025-09-24 23:28:21 +00:00
zeertzjq
ca377f3c35 vim-patch:1ae980a: runtime(doc): fix inconsistent indent in cmdline.txt
Also fix typo in autoload/netrw.vim.

related: vim/vim#18371
closes: vim/vim#18376

1ae980a9cb
2025-09-25 06:50:44 +08:00
zeertzjq
641cb41832 vim-patch:34747a1: runtime(doc): update live-grep and fuzzy-file-picker examples
closes: vim/vim#18371

34747a13e0

Co-authored-by: Konfekt <Konfekt@users.noreply.github.com>
2025-09-25 06:50:44 +08:00
zeertzjq
d954763b85 vim-patch:b1446df: runtime(vim): Update base syntax, match :wincmd (#35898)
Match the full :wincmd command syntax.

Allow for oneline assignment to Vim9 variables named winc[md].

Fixes vim/vim#18368.

b1446dfd23

Co-authored-by: Doug Kearns <dougkearns@gmail.com>
2025-09-24 10:22:46 +08:00
zeertzjq
b7742714aa vim-patch:20e78ee: runtime(swayconfig): support new config options in syntax script
From sway(5):
 - allow_tearing
 - primary_selection
 - swaybg_command
 - swaynag_command

From sway-output(5):
 - color_profile
 - allow_tearing

From sway-input(5):
 - clickfinger_button_map
 - rotation_angle
 - scroll_button_lock

closes: vim/vim#18293

20e78ee807

Co-authored-by: Felix Pehla <29adc1fd92@gmail.com>
2025-09-24 08:38:15 +08:00
zeertzjq
0c23b863f4 vim-patch:9.1.1787: filetype: not all Sway config files are recognized
Problem:  filetype: not all Sway config files are recognized
Solution: Detect files within */sway/config.d/* as swayconfig filetype
          (Felix Pehla).

Sways default config automatically includes files placed in
@sysconfdir@/sway/config.d/* (see config.in), so it makes sense to use
the sway syntax for those.

related: vim/vim#18293

24f0dbba8c

Co-authored-by: Felix Pehla <29adc1fd92@gmail.com>
2025-09-24 08:36:53 +08:00
zeertzjq
409122e5ae vim-patch:11bde1f: runtime(sh): refactored sh.vim syntax script (#35895)
- unified bashStatement, kshStatement and shStatement as much as
  possible
- separated builtin commands from external programs
- cleaned up kornshell flavor logic
- fixed alias syntax highlighting
- added test for bash alias syntax highlighting
- removed daemon keyword

closes: vim/vim#18355

11bde1f169

Co-authored-by: Bjoern Foersterling <bjoern.foersterling@gmail.com>
2025-09-24 00:28:38 +00:00
zeertzjq
dd630e7f84 vim-patch:5830407: runtime(netrw): 'equalalways' is not always respected (#35894)
fixes: vim/vim#18358

58304078ad

Co-authored-by: Christian Brabandt <cb@256bit.org>
2025-09-24 00:03:38 +00:00