Commit Graph

24012 Commits

Author SHA1 Message Date
zeertzjq
52b3e8bdef vim-patch:9.0.1016: screenpos() does not count filler lines for diff mode
Problem:    screenpos() does not count filler lines for diff mode.
Solution:   Add filler lines. (closes 11658)

1cb16c3a20

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-06 08:02:39 +08:00
zeertzjq
0909d987fe vim-patch:9.0.1011: ml_get error when using screenpos()
Problem:    ml_get error when using screenpos().
Solution:   Give an error for the line number. (closes vim/vim#11661)

99d19438ca

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-06 08:00:17 +08:00
zeertzjq
10af0549df vim-patch:8.2.4389: screenpos() does not handle a position in a closed fold
Problem:    screenpos() does not handle a position in a closed fold.
Solution:   Check if the position is inside a closed fold. (closes vim/vim#9778)

4556a2e868

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-06 07:51:32 +08:00
zeertzjq
6f9cda0f0a vim-patch:8.2.4204: screenpos() has non-zero row for invisible text
Problem:    screenpos() has non-zero row for invisible text.
Solution:   Only add the window row when the text is visible. (closes vim/vim#9618)

7924a17791

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-06 07:40:16 +08:00
zeertzjq
e120a049f0 fix(float): fix ml_get error with bufpos 2022-12-06 07:40:16 +08:00
zeertzjq
11d2704274 vim-patch:8.2.3193: screenpos() is wrong when 'display' is "lastline"
Problem:    screenpos() is wrong when the last line is partially visible and
            'display' is "lastline".
Solution:   Also compute the position for a partially visible line.
            (closes vim/vim#8599)

189663bdac

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-06 07:40:16 +08:00
ii14
f3bf1fbf60
fix(secure): crash when hitting escape in prompt (#21283)
- use pcall when calling vim.secure.read from C
- catch keyboard interrupts in vim.secure.read, rethrow other errors
- selecting "view" in prompt runs :view command
- simplify lua stack cleanup with lua_gettop and lua_settop

Co-authored-by: ii14 <ii14@users.noreply.github.com>
2022-12-05 11:59:04 -07:00
zeertzjq
707df88054
docs: add missing docs from some Vim patches (#21296)
This is cherry-picked from these Vim patches:

Only applicable change outside vi_diff.txt in patch 8.1.1226:
6c60f47fb9

Most changes outside starting.txt and vi_diff.txt in patch 8.1.1280:
25c9c680ec

Missing docs for 'mousemoveevent':
cbaff5e06e
2022-12-05 21:09:31 +08:00
dundargoc
6c285a6e49
ci: create CI job to check if news needs to be updated (#21142)
If any commit message in the PR is either of type "feat" or is a
breaking change, then there's a high probability that news.txt should be
updated. Give an error if news.txt hasn't been updated in that case.

This workflow cannot 100% correctly determine if news.txt should be
updated even if the commit messages were exactly correct. The entries in
news.txt is determined by changes between releases, while the commit
messages are based on the master branch. While it is an approximation,
it is still a useful enough one that it's still valuable to have this
job as a reminder even if it gives an error if it shouldn't. In these
cases it is perfectly fine to ignore the failure for this job.
2022-12-05 11:58:30 +01:00
dundargoc
5c52971f60
ci: use shell script to deduplicate workflow (#21079) 2022-12-05 11:58:13 +01:00
dundargoc
9d8dbd9846
ci: use local action to make make cache keys consistent (#20538)
The advantages of using an action is that it reduces boilerplate and
repetition from the main ci.yml workflow.
2022-12-05 11:57:52 +01:00
zeertzjq
89374da798
vim-patch:8.2.2328: some test files may not be deleted (#21194)
Problem:    Some test files may not be deleted.
Solution:   Add a delete() call, correct name. (Dominique Pellé, closes vim/vim#7654)

48e11c1054
2022-12-05 10:47:05 +08:00
zeertzjq
1c6f7e5933
Merge pull request #21292 from zeertzjq/vim-8.2.1195
vim-patch:8.2.{1195,1197,2240,3108,3109,3495,3499,3526,5145}
2022-12-05 10:22:47 +08:00
zeertzjq
9ae6b03e7a vim-patch:8.2.5145: exit test causes spurious valgrind reports
Problem:    Exit test causes spurious valgrind reports.
Solution:   Skip test.  Add CheckNotValgrind.

cf801d4b95

Cherry-pick RunningWithValgrind() from patch 8.2.5136.

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-05 09:55:18 +08:00
zeertzjq
ba9fcc22ef vim-patch:8.2.3526: tests have clumsy check for X11 based GUI
Problem:    Tests have clumsy check for X11 based GUI.
Solution:   Add CheckX11BasedGui.

40bd5a1540

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-05 09:55:18 +08:00
zeertzjq
e043dbf0aa vim-patch:8.2.3499: GUI geometry startup test fails
Problem:    GUI geometry startup test fails.
Solution:   Check string values instead of numbers

3d031a0ae7

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-05 09:55:18 +08:00
zeertzjq
78fa1f069d vim-patch:8.2.3495: GUI geometry startup test fails on some systems
Problem:    GUI geometry startup test fails on some systems. (Drew Vogel)
Solution:   Add tolerance to the size check. (closes vim/vim#8815)

b376aa2da4

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-05 09:55:18 +08:00
zeertzjq
e9ad613fdf vim-patch:8.2.3109: check for $DISPLAY never fails
Problem:    Check for $DISPLAY never fails.
Solution:   Use eval().

f6d877975b

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-05 09:51:08 +08:00
zeertzjq
adcf7a2219 vim-patch:8.2.3108: test for remote_foreground() fails
Problem:    Test for remote_foreground() fails. (Elimar Riesebieter)
Solution:   Check that $DISPLAY is set. (Christian Brabandt)

d6fa7bd5b9

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-05 09:50:54 +08:00
zeertzjq
060789e335 vim-patch:8.2.2240: clientserver test fails if full path is used
Problem:    Clientserver test fails if full path is used.
Solution:   Ignore the path preceding the file name.

41a834d1e3

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-05 09:50:18 +08:00
zeertzjq
ee944ef103 vim-patch:8.2.1197: clientserver test still fails on MS-Windows
Problem:    Clientserver test still fails on MS-Windows.
Solution:   Expect a different error message.

c212dd0a34

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-05 09:49:44 +08:00
zeertzjq
5d691a4669 vim-patch:8.2.1195: clientserver test fails on MS-Windows
Problem:    Clientserver test fails on MS-Windows.
Solution:   Expect a different error message.

4d57ba0202

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-05 09:49:32 +08:00
Mathias Fußenegger
b098e7971f
fix(lsp): ensure open_logfile is safe for fast events (#21288)
Closes https://github.com/neovim/neovim/issues/21052
2022-12-04 18:02:24 +01:00
Mathias Fußenegger
ec6ba87229
Merge pull request #21287 from mfussenegger/lsp-show-document
fix(lsp): call show_document with correct args
2022-12-04 16:29:05 +01:00
Mathias Fussenegger
67e1390dc8 fix(lsp): call show_document with correct args
Closes https://github.com/neovim/neovim/issues/21177
2022-12-04 15:57:46 +01:00
Mathias Fussenegger
48b84d6d6e refactor(lsp): extract a _create_server method in lsp_spec 2022-12-04 15:39:22 +01:00
Raphael
01a8cd0432
fix(lsp): remove workspaceFolders field (#21284) 2022-12-04 14:56:04 +01:00
zeertzjq
b866d8d2e7
vim-patch:9.0.0610: global interrupt test fails when run under valgrind (#21285)
Problem:    Global interrupt test fails when run under valgrind.
Solution:   Use TermWait().

859ea4bc76

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-04 18:33:04 +08:00
zeertzjq
9263f17d0d
vim-patch:9.0.0259: crash with mouse click when not initialized (#21282)
Problem:    Crash with mouse click when not initialized.
Solution:   Check TabPageIdxs[] is not NULL.

80525751c5

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-04 17:44:51 +08:00
zeertzjq
823247a040
Merge pull request #21281 from zeertzjq/vim-8.2.4163
vim-patch:8.2.{4163,4168}
2022-12-04 16:59:45 +08:00
zeertzjq
d93b906254 vim-patch:8.2.4168: disallowing empty function name breaks existing plugins
Problem:    Disallowing empty function name breaks existing plugins.
Solution:   Allow empty function name in legacy script.

e6a4200ff4

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-04 16:34:01 +08:00
zeertzjq
32810c0818 vim-patch:8.2.4163: no error for omitting function name after autoload prefix
Problem:    No error for omitting function name after autoload prefix.
Solution:   Check for missing function name. (issue vim/vim#9577)

2017d6f3b1

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-04 16:29:26 +08:00
zeertzjq
a0dd663c2d
Merge pull request #21279 from zeertzjq/vim-8.2.2182
vim-patch:8.2.{2182,2295,3265,3292}: search fixes
2022-12-04 10:32:20 +08:00
zeertzjq
9476dd2f92 vim-patch:8.2.3292: underscore in very magic pattern causes a hang
Problem:    Underscore in very magic pattern causes a hang.  Pattern with \V
            are case sensitive. (Yutao Yuan)
Solution:   Adjust condition for magicness and advance pointer. (Christian
            Brabandt, closes vim/vim#8707, closes vim/vim#8704, closes vim/vim#8705)

bc67e5a0a4

Co-authored-by: Christian Brabandt <cb@256bit.org>
2022-12-04 10:07:05 +08:00
zeertzjq
3f1ee12d31 vim-patch:8.2.3265: smartcase does not work correctly in very magic pattern
Problem:    Smartcase does not work correctly in very magic pattern.
Solution:   Take the magicness into account when skipping over regexp items.
            (Christian Brabandt, closes vim/vim#8682, closes vim/vim#7845)

78ba933d18

Co-authored-by: Christian Brabandt <cb@256bit.org>
2022-12-04 10:07:05 +08:00
zeertzjq
46e4be0fd0 vim-patch:8.2.2295: incsearch does not detect empty pattern properly
Problem:    Incsearch does not detect empty pattern properly.
Solution:   Return magic state when skipping over a pattern. (Christian
            Brabandt, closes vim/vim#7612, closes vim/vim#6420)

d93a7fc1a9
2022-12-04 10:07:05 +08:00
zeertzjq
a91ba088ab vim-patch:8.2.2182: Vim9: value of 'magic' is still relevant
Problem:    Vim9: value of 'magic' is still relevant.
Solution:   Always behave like 'magic' is on in Vim9 script (closes vim/vim#7509)

f4e2099e39

EX_NONWHITE_OK is N/A: only applies to Vim9 script.

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-04 10:07:04 +08:00
Christian Clason
fba0562723
fix(syntax): correct conceal for annotated code blocks (#21272)
fixup for https://github.com/neovim/neovim/pull/21154
2022-12-03 15:16:37 +01:00
zeertzjq
e642825e28
Merge pull request #21274 from zeertzjq/vim-8.2.3992
vim-patch:8.2.{3992,4261,4262},9.0.{0110,0577}
2022-12-03 21:44:13 +08:00
zeertzjq
0cb90114d4 vim-patch:9.0.0577: buffer underflow with unexpected :finally
Problem:    Buffer underflow with unexpected :finally.
Solution:   Check CSF_TRY can be found.

96b9bf8f74

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-03 21:21:47 +08:00
zeertzjq
bf4bf7f9e0 vim-patch:9.0.0110: help tag generation picks up words in code examples
Problem:    Help tag generation picks up words in code examples.
Solution:   Skip over examples. (Carlo Teubner, closes vim/vim#10813)

ddab3ce345

Also fix mistakes in help files.

Co-authored-by: Carlo Teubner <carlo@cteubner.net>
2022-12-03 21:21:47 +08:00
zeertzjq
3838ee63d0 test(old): skip Vim9 script with less divergence 2022-12-03 21:21:47 +08:00
zeertzjq
742d95a629 vim-patch:8.2.4262: some search tests fail
Problem:    Some search tests fail.
Solution:   Use a better way to reject searching for the Visual area.

44a4d947bb

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-03 21:21:47 +08:00
zeertzjq
f6caa35e65 vim-patch:8.2.4261: accessing invalid memory in a regular expression
Problem:    Accessing invalid memory when a regular expression checks the
            Visual area while matching in a string.
Solution:   Do not try matching the Visual area in a string.

679d66c2d2

Use CheckScriptFailure() instead of v9.CheckScriptFailure().

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2022-12-03 21:21:47 +08:00
zeertzjq
b69c581761 vim-patch:8.2.3992: wrong local-additions in the help with language mix
Problem:    Wrong local-additions in the help with language mix.
Solution:   Adjust how the local additions list is generated. (Hirohito
            Higashi, closes vim/vim#9464)

0e2508d9e6

Co-authored-by: h-east <h.east.727@gmail.com>
2022-12-03 21:21:47 +08:00
zeertzjq
e7a2ae829a test(old): make ":h local-additions" work properly in test_help.vim 2022-12-03 21:21:47 +08:00
Folke Lemaitre
c768b578fa
fix(lsp): render <pre>{lang} code blocks and set separator default to false (#21271) 2022-12-03 13:51:57 +01:00
zeertzjq
8f1ef36875
Merge pull request #21270 from zeertzjq/vim-8.2.1420
vim-patch:8.2.{1420,1440}: test 49 is old style
2022-12-03 15:09:46 +08:00
zeertzjq
7d283d2139 vim-patch:8.2.1440: debugger code insufficiently tested
Problem:    Debugger code insufficiently tested.
Solution:   Add a few more tests. (Yegappan Lakshmanan, closes vim/vim#6700)

16c6232cad
2022-12-03 14:47:35 +08:00
zeertzjq
8a29d9660e vim-patch:8.2.1420: test 49 is old style
Problem:    Test 49 is old style.
Solution:   Convert remaining parts to new style. Remove obsolete items.
            (Yegappan Lakshmanan, closes vim/vim#6683)

f7c4d83609
2022-12-03 14:47:35 +08:00