Commit Graph

22546 Commits

Author SHA1 Message Date
dundargoc
ac78639de8
docs: .git-blame-ignore-revs (#18579)
add "refactor(uncrustify): enable formatting for regexp and indent files" (#18549)
2022-08-12 15:05:08 +02:00
bfredl
54a165d9a6
Merge pull request #19592 from dundargoc/refactor/char_u-to-char
refactor: replace char_u with char
2022-08-12 14:44:28 +02:00
Dundar Goc
094cdf2d69 refactor: replace char_u with char
Work on https://github.com/neovim/neovim/issues/459
2022-08-12 14:22:02 +02:00
zeertzjq
f79773a3b4
refactor: move non-symbols in ex_eval.h to ex_eval_defs.h (#19739)
This avoids including ex_eval.h in any other header, thus preventing
future circular includes.
2022-08-12 19:16:24 +08:00
Jonas Strittmatter
1cf3a4b409
docs: clarify that cursorline will be disabled before command preview (#19710) 2022-08-12 10:21:50 +02:00
Mathias Fußenegger
02289ab898
fix(lsp): fix nil value error in get_group (#19735)
`server_capabilities` can be nil until the server is initialized.
Reproduced with:

    vim.lsp.stop_client(vim.lsp.start_client {
      cmd = { vim.v.progpath, '-es', '-u', 'NONE', '--headless' };
    })
2022-08-12 10:10:03 +02:00
zeertzjq
103f10d901
refactor: move code dealing with script files to runtime.c (#19734)
vim-patch:8.1.1927: code for dealing with script files is spread out

Problem:    Code for dealing with script files is spread out.
Solution:   Move the code to scriptfile.c. (Yegappan Lakshmanan, closes vim/vim#4861)
307c5a5bb7
2022-08-12 15:41:43 +08:00
zeertzjq
d4f5e0db3c
Merge pull request #19733 from zeertzjq/vim-8.1.1684
vim-patch:8.1.{1684,1689}: profiling code is spread out
2022-08-12 14:39:47 +08:00
zeertzjq
a93d29589a vim-patch:8.1.1689: profiling code is spread out
Problem:    Profiling code is spread out.
Solution:   Move more profiling code to profiler.c. (Yegappan Lakshmanan,
            closes vim/vim#4668)
660a10ad41
2022-08-12 14:15:03 +08:00
zeertzjq
c7ca94ba7f vim-patch:8.1.1684: profiling functionality is spread out
Problem:    Profiling functionality is spread out.
Solution:   Put profiling functionality in profiling.c. (Yegappan Lakshmanan,
            closes vim/vim#4666)
fa55cfc69d

Move proftime_T to types.h for now to avoid recursive #include.
2022-08-12 13:44:37 +08:00
zeertzjq
0d9e09bf67
test: make Ex mode exit test test what it wants to test (#19728) 2022-08-12 09:04:08 +08:00
Mathias Fußenegger
33b77eb728
fix(lsp): handle nil client in onexit callback (#19722)
Follow up to https://github.com/neovim/neovim/pull/19658
2022-08-11 19:21:57 +02:00
Lewis Russell
a27756cc24
fix(signs): priority of extmark signs (#19718) 2022-08-11 17:26:17 +01:00
Mathias Fußenegger
996fc2256b
fix(lsp): avoid pipe leaks if lsp cmd isn't executable (#19717)
The `onexit` handler isn't called if `uv.spawn` doesn't return a handle.
2022-08-11 17:04:55 +02:00
Mathias Fußenegger
8b67f37798
fix(lsp): fix some type annotations in lsp.rpc (#19714) 2022-08-11 15:17:05 +02:00
Christian Clason
6669fc94ae
docs: add reformat commit to .git-blame-ignore-revs (#19715)
followup to #19685
2022-08-11 14:41:15 +02:00
Christian Clason
d1fb0dd8b9
Merge pull request #19685 from ii14/gen_vimdoc_indentation
docs: change gen_vimdoc indentation level
2022-08-11 14:34:00 +02:00
ii14
ea333badd2 docs: regenerate 2022-08-11 14:25:48 +02:00
ii14
d2975d58cb docs: change gen_vimdoc indentation to 4 spaces 2022-08-11 14:25:18 +02:00
zeertzjq
94c3176478
refactor: use CLEAR_FIELD and CLEAR_POINTER macros (#19709)
vim-patch:8.2.0559: clearing a struct is verbose

Problem:    Clearing a struct is verbose.
Solution:   Define and use CLEAR_FIELD() and CLEAR_POINTER().
a80faa8930
2022-08-11 15:44:55 +08:00
Christian Clason
252dea5927
build(deps): bump LuaJIT to HEAD - 633f265f6 (#19703) 2022-08-11 08:53:15 +02:00
bfredl
b4b22318a1
Merge pull request #19704 from bfredl/ceci-nest-pas-un-bool
fix(mpack): make sure a `bool` always is a `bool`
2022-08-10 22:31:53 +02:00
bfredl
faccae47fc fix(mpack): make sure a bool always is a bool
before, RelWithDebInfo linking gave this warning:

    src/mpack/conv.h:36:16: warning: type of ‘mpack_unpack_boolean’ does not match original declaration [-Wlto-type-mismatch]
       36 | MPACK_API bool mpack_unpack_boolean(mpack_token_t t) FUNUSED FPURE;
          |                ^
    src/mpack/conv.c:196:16: note: return value type mismatch
      196 | MPACK_API bool mpack_unpack_boolean(mpack_token_t t)
          |                ^
2022-08-10 20:36:28 +02:00
Jonas Strittmatter
ff1266aaaa
vim-patch:9.0.0182: quarto files are not recognized (#19702)
Problem:    Quarto files are not recognized.
Solution:   Recognize quarto files by the extension. (Jonas Strittmatter,
            closes vim/vim#10880)
3a9687fb27
2022-08-10 13:44:57 +02:00
Famiu Haque
78658ef383
fix(api): vim.cmd.make crashes when argument count isn't 1 (#19701)
Closes #19696
2022-08-10 18:37:59 +08:00
dundargoc
3ee6c05b4b
Merge pull request #19693 from clason/bump-gha-ubuntu 2022-08-10 08:55:25 +02:00
zeertzjq
512e0441f1
docs: fix some mistakes and missing docs (#19699) 2022-08-10 12:47:38 +08:00
Mathias Fußenegger
bebfbfab3b
fix(lsp): handle multiple clients with incremental sync (#19658)
The change tracking used a single lines/lines_tmp table to track
changes to a buffer.

If multiple clients using incremental sync are connected to a buffer,
they both made changes to the same lines table. That resulted in an
inconsistent state.

This commit changes the didChange handling to group clients by
synchronization scheme and offset encoding.
This avoids computing the diff multiple times for clients using the
same scheme and resolves the lines/lines_tmp conflicts.

Fixes https://github.com/neovim/neovim/issues/19325
2022-08-09 22:20:40 +02:00
Christian Clason
d212dfd676 ci(release): build with standard gcc on Ubuntu
Ubuntu-20.04 ships with GCC 10.3.0, which is enough to avoid #14150
2022-08-09 18:10:18 +02:00
Christian Clason
48241c3b23 ci(release): bump deprecated ubuntu image to 20.04
`ubuntu-18.04` is now deprecated and subject to outages, see
  https://github.blog/changelog/2022-08-09-github-actions-the-ubuntu-18-04-actions-runner-image-is-being-deprecated-and-will-be-removed-by-12-1-22/
2022-08-09 18:10:18 +02:00
zeertzjq
3030b4d653
feat(tui): allow grid and host to disagree on ambiguous-width chars (#19686)
Note: This only applies to ambiguous-width characters.
2022-08-09 21:08:46 +08:00
zeertzjq
24bf0490ea
vim-patch:9.0.0176: checking character options is duplicated and incomplete (#19690)
Problem:    Checking character options is duplicated and incomplete.
Solution:   Move checking to check_chars_options(). (closes vim/vim#10863)
8ca29b6a35
2022-08-09 20:35:34 +08:00
Christian Clason
33ddca6fa0
docs(lua): add luv (vim.loop) reference manual (#19679)
Upstreamed from https://github.com/nanotee/luv-vimdocs with kind
permission from @nanotee.
2022-08-09 13:21:50 +02:00
zeertzjq
cd14efd281
vim-patch:8.1.1823: command line history code is spread out (#19688)
Problem:    Command line history code is spread out.
Solution:   Put the code in a new file. (Yegappan Lakshmanan, closes vim/vim#4779)
            Also graduate the +cmdline_hist feature.
d7663c22c6
2022-08-09 17:13:44 +08:00
Christian Clason
a5e846b996
vim-patch:partial: 48c3f4e0bff7 (#19684)
vim-patch:partial:48c3f4e0bff7

Update runtime files
48c3f4e0bf

partially skip `options.txt` (needs 9.0.0138)
2022-08-09 10:43:28 +02:00
dundargoc
e6680ea7c3
docs(lua): add Lua 5.1 reference manual (#19663)
based on http://www.vim.org/scripts/script.php?script_id=1291
reformatted to match Nvim documentation style; removed irrelevant sections

Co-authored-by: dundargoc <gocundar@gmail.com>
Co-authored-by: Christian Clason <c.clason@uni-graz.at>
Co-authored-by: Lewis Russell <lewis6991@gmail.com>
2022-08-08 18:58:32 +02:00
Mathias Fußenegger
68c674af0f
feat(lsp): set formatexpr by default (#19677)
Follow up to https://github.com/neovim/neovim/pull/19003
2022-08-08 18:30:17 +02:00
zeertzjq
d31ee6664d
test: increse expect_exit() timeouts (#19680)
A timeout of 100 milliseconds is sometimes still too short for macOS.
Change it to 1000 milliseconds.
2022-08-08 22:04:21 +08:00
zeertzjq
d36c2fa713
Merge pull request #19674 from zeertzjq/vim-8.2.1535
vim-patch:8.2.{1535,1537,3545}: setcellwidths()
2022-08-08 21:20:27 +08:00
zeertzjq
603f7bd253 fix(fillchars): change fallback after setcellwidths() 2022-08-08 20:03:40 +08:00
zeertzjq
9fedb6fd78 vim-patch:8.2.3545: setcellwidths() may make 'listchars' or 'fillchars' invalid
Problem:    setcellwidths() may make 'listchars' or 'fillchars' invalid.
Solution:   Check the value and give an error. (closes vim/vim#9024)
94358a1e6e

Cherry-pick f_setcellwidths() change from patch 9.0.0036.
Cherry-pick 'ambiwidth' docs update from runtime update 079ba76ae7a7.
2022-08-08 20:03:40 +08:00
zeertzjq
01a7009af9 refactor(setcellwidths): use TV_LIST_ITEM_NEXT properly 2022-08-08 20:03:40 +08:00
zeertzjq
967415d527 vim-patch:8.2.1537: memory acccess error when using setcellwidths()
Problem:    Memory acccess error when using setcellwidths().
Solution:   Use array and pointers correctly.
b06a6d59d1
2022-08-08 20:03:40 +08:00
zeertzjq
53c9500c1d vim-patch:8.2.1535: it is not possible to specify cell widths of characters
Problem:    It is not possible to specify cell widths of characters.
Solution:   Add setcellwidths().
08aac3c619

Co-Authored-By: delphinus <me@delphinus.dev>
2022-08-08 20:03:40 +08:00
zeertzjq
bc8fbb7c1d refactor: move non-symbols in mbyte.h to mbyte_defs.h
This just avoids including mbyte.h in eval/typval.h, so that mbyte.h can
include eval/typval.h in Vim patch 8.2.1535.
2022-08-08 20:03:40 +08:00
Mathias Fußenegger
a46e6afb8b
fix(lsp): set end_col in formatexpr (#19676)
The last line was excluded from formatting via formatexpr because the
character in the params was set to 0 instead of the end of line.
2022-08-08 13:02:15 +02:00
Mathias Fußenegger
2d5fce2cdb
feat(lsp): disable exit_timeout by default (#19672)
The lsp client used to wait up to 500ms for a language server to
shutdown before sending a TERM signal.

The intention behind the 500ms grace period was to ensure the language
server exits to prevent stale processes, but it has the side-effect that
it can interrupt language-servers which are too slow to shutdown within
500ms. Language servers tend to write out index files or project files
on shutdown, and being interrupted during this process can cause
corruption of those files.

This changes the default to not wait at all, at the risk of leaving
stale processes around if the language server isn't well behaved.

An alternative would be to wait indefinitely, but that can cause neovim
to take several seconds to exit.
2022-08-08 12:34:37 +02:00
zeertzjq
18766e742b
fix(folds): fix fold remains when :delete makes buffer empty (#19673) 2022-08-08 06:07:59 +08:00
zeertzjq
629169462a
fix(terminal): skip aucmd_win when checking terminal size (#19668) 2022-08-07 19:43:29 +08:00
zeertzjq
fa8b2b4c50
vim-patch:8.2.4492: no error if an option is given a value with ":let &opt = val" (#19670)
Problem:    No error if an option is given an invalid value with
            ":let &opt = val".
Solution:   Give the error. (closes vim/vim#9864)
8ccbbeb620
2022-08-07 17:11:03 +08:00