aboutsummaryrefslogtreecommitdiff
path: root/test
Commit message (Collapse)AuthorAge
...
* | | fix(extmarks): fix heap buffer overflow caused by inline virtual text (#23851)Ibby2023-06-24
| |/ |/| | | also fixes an edge case where the extends character would not be drawn if the real text exactly fits the grid.
* | fix(cmdline): don't redraw 'tabline' in Ex mode (#24123)zeertzjq2023-06-23
| | | | | | | | | | | | | | | | Redrawing of 'statusline' and 'winbar' are actually already inhibited by RedawingDisabled in Ex mode. In Vim there is a check for `msg_scrolled == 0` (which is false in Ex mode) since Vim doesn't have msgsep. Add a `!exmode_active` check here in Nvim instead.
* | feat(lsp): opt-in to dynamicRegistration for inlay hints (#24102)Mathias Fußenegger2023-06-22
| | | | | | | | | | Since https://github.com/neovim/neovim/pull/23681 there is dynamic registration support. We should use that for new features unless there is a good reason to turn it off.
* | vim-patch:9.0.1645: zserio files are not recognized (#24120)Christian Clason2023-06-22
| | | | | | | | | | | | | | | | | | Problem: zserio files are not recognized. Solution: Add a pattern for zserio files. (Dominique Pellé, closes vim/vim#12544) https://github.com/vim/vim/commit/2b994da57a0ac6ec0ec09fe3783f48ecd2bce610 Co-authored-by: =?UTF-8?q?Dominique=20Pell=C3=A9?= <dominique.pelle@gmail.com>
* | feat(extmarks): support hl_mode "combine" for inline virt_text (#24099)zeertzjq2023-06-22
| |
* | fix(messages): use "Vimscript" instead of "VimL" #24111Justin M. Keyes2023-06-22
| | | | | | | | followup to #24109 fix #16150
* | test: spellcheck :help (vimdoc) files #24109Justin M. Keyes2023-06-22
| | | | | | | | | | | | | | Enforce consistent terminology (defined in `gen_help_html.lua:spell_dict`) for common misspellings. This does not spellcheck English in general (perhaps a future TODO, though it may be noisy).
* | fix(extmarks): hide inline virt_text properly with 'smoothscroll' (#24106)zeertzjq2023-06-22
| |
* | fix(extmarks): empty inline virt_text interfering with DiffText (#24101)zeertzjq2023-06-22
| |
* | fix(api): wrong nvim_buf_set_extmark error for invalid hl_modezeertzjq2023-06-22
| |
* | fix(extmarks): empty inline virt_text interfering with Visual highlightzeertzjq2023-06-22
| |
* | fix(folds): don't show search or match highlighting on fold (#24084)zeertzjq2023-06-21
| |
* | fix(vim.json)!: remove global options, "null", "array_mt" #24070Justin M. Keyes2023-06-21
|/ | | | | | | | | | | | | | | | | | | | | | | | | Problem: - `vim.json` exposes various global options which: - affect all Nvim Lua plugins (especially the LSP client) - are undocumented and untested - can cause confusing problems such as: https://github.com/codota/tabnine-nvim/commit/cc76ae3abe2f129d44b5a8edee2529e0ee0dcf69 - `vim.json` exposes redundant mechanisms: - `vim.json.null` is redundant with `vim.NIL`. - `array_mt` is redundant because Nvim uses a metatable (`vim.empty_dict()`) for empty dict instead, which `vim.json` is configured to use by default (see `as_empty_dict`). Example: ``` :lua vim.print(vim.json.decode('{"bar":[],"foo":{}}')) --> { bar = {}, foo = vim.empty_dict() } ``` Thus we don't need to also decorate empty arrays with `array_mt`. Solution: Remove the functions from the public vim.json interface. Comment-out the implementation code to minimize drift from upstream. TODO: - Expose the options as arguments to `vim.json.new()`
* fix(lsp): always return boolean in lsp.buf_client_attach (#24077)Sooryakiran Ponnath2023-06-20
| | | Co-authored-by: Mathias Fussenegger <f.mathias@zignar.net>
* refactor(lsp): extract common execute command functionality (#24065)Mathias Fußenegger2023-06-20
|
* feat(lsp): inlay hints #23984Chinmay Dalal2023-06-19
| | | | | | | | | | | Add automatic refresh and a public interface on top of #23736 * add on_reload, on_detach handlers in `enable()` buf_attach, and LspDetach autocommand in case of manual detach * unify `__buffers` and `hint_cache_by_buf` * use callback bufnr in `on_lines` callback, bufstate: remove __index override * move user-facing functions into vim.lsp.buf, unify enable/disable/toggle Closes #18086
* docs #22363Justin M. Keyes2023-06-19
| | | | | | | | | Co-authored by: zeertzjq <zeertzjq@outlook.com> Co-authored by: Steven Todd McIntyre II <114119064+stmii@users.noreply.github.com> Co-authored by: nobe4 <nobe4@users.noreply.github.com> - docs: mention --luadev-mod to run with lua runtime files When changing a lua file in the ./runtime folder, a new contributor might expect changes to be applied to the built Neovim binary.
* fix(fs): make `normalize()` work with '/' path (#24047)Evgeni Chasnovski2023-06-18
| | | | | | | Problem: Current implementation of "remove trailing /" doesn't account for the case of literal '/' as path. Solution: Remove trailing / only if it preceded by something else. Co-authored by: notomo <notomo.motono@gmail.com>
* fix(lsp): allow Lua pattern chars in code action filter (#24041)Jonas Strittmatter2023-06-17
| | | | | | | Previously, filtering code actions with the "only" option failed if the code action kind contained special Lua pattern chars such as "-" (e.g. the ocaml language server supports a "type-annotate" code action). Solution: use string comparison instead of string.find
* vim-patch:9.0.1635: error message is cleared when removing mode messagezeertzjq2023-06-16
| | | | | | | | | Problem: Error message is cleared when removing mode message. Solution: Also reset flags when the message is further down. https://github.com/vim/vim/commit/da51ad51bf4fbd66619786d0e6a83fb3ca09930b Co-authored-by: Bram Moolenaar <Bram@vim.org>
* vim-patch:9.0.1634: message is cleared when removing mode messagezeertzjq2023-06-16
| | | | | | | | | Problem: Message is cleared when removing mode message (Gary Johnson). Solution: Do not clear the command line after displaying a message. https://github.com/vim/vim/commit/800cdbb7caeb5dd4379c6cb071bb12391f20bcf3 Co-authored-by: Bram Moolenaar <Bram@vim.org>
* vim-patch:9.0.1636: expanding a pattern interferes with cmdline completion ↵zeertzjq2023-06-16
| | | | | | | | (#24034) Problem: Expanding a pattern interferes with command line completion. Solution: Set the file index only when appropriate. (closes vim/vim#12519) https://github.com/vim/vim/commit/094dd152fe1d47878ec6c0b3f54b03ffde7f4a2d
* fix(:let): fix error when applying operator to boolean option (#24030)zeertzjq2023-06-15
|
* test(decorations_spec): add test for extmark case of #21486 (#24028)zeertzjq2023-06-15
|
* fix(extmarks): don't position overlay virt_text halfway a char (#24027)zeertzjq2023-06-15
|
* vim-patch:9.0.1631: passing wrong variable type to option gives multiple ↵zeertzjq2023-06-15
| | | | | | | | errors (#24026) Problem: Passing a wrong variable type to an option gives multiple errors. Solution: Bail out early on failure. (closes vim/vim#12504) https://github.com/vim/vim/commit/4c7cb372c17a84c8a35254d93eb37cb854cd39da
* vim-patch:9.0.1629: having utf16idx() rounding up is inconvenient (#24019)zeertzjq2023-06-14
| | | | | | | | Problem: Having utf16idx() rounding up is inconvenient. Solution: Make utf16idx() round down. (Yegappan Lakshmanan, closes vim/vim#12523) https://github.com/vim/vim/commit/95707037afa1aeae4f3494dc623a721ceed7fc4e Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
* perf(lsp): reduce polling handles for workspace/didChangeWatchedFiles (#23500)Jon Huhn2023-06-14
| | | Co-authored-by: Lewis Russell <lewis6991@gmail.com>
* fix(extmarks): handle inline virt_text with empty chunk (#24005)zeertzjq2023-06-13
|
* vim-patch:8.2.4600: Vim9: not enough test coverage for executing :def ↵zeertzjq2023-06-12
| | | | | | | | | | | | function (#24001) Problem: Vim9: not enough test coverage for executing :def function. Solution: Add a few more tests. Fix inconsistencies. https://github.com/vim/vim/commit/6b8c7ba062ca4b50e8f983e0485be7afa4eef691 Cherry-pick a blank line in test_listdict.vim from patch 8.2.3842. Co-authored-by: Bram Moolenaar <Bram@vim.org>
* vim-patch:8.2.3338: Vim9: no type check when assigning a list rangezeertzjq2023-06-12
| | | | | | | | | Problem: Vim9: no type check when assigning a list range. (Naohiro Ono) Solution: Check the member type. (closes vim/vim#8750) https://github.com/vim/vim/commit/89071cb6a116a74f78f77a1853e6fada44872a15 Co-authored-by: Bram Moolenaar <Bram@vim.org>
* vim-patch:8.2.3332: Vim9: cannot assign to range in listzeertzjq2023-06-12
| | | | | | | | | Problem: Vim9: cannot assign to range in list. Solution: Implement overwriting a list range. https://github.com/vim/vim/commit/4f0884d6e24d1d45ec83fd86b372b403177d3298 Co-authored-by: Bram Moolenaar <Bram@vim.org>
* vim-patch:8.2.3853: Vim9: not enough testszeertzjq2023-06-12
| | | | | | | | | | | Problem: Vim9: not enough tests. Solution: Run more existing tests for Vim9 script. https://github.com/vim/vim/commit/700e6b166298ecfb53fe4bf593085b29ca78d556 Cherry-pick test_listdict.vim change from patch 8.2.3854. Co-authored-by: Bram Moolenaar <Bram@vim.org>
* vim-patch:8.2.3852: Vim9: not enough testszeertzjq2023-06-12
| | | | | | | | | | Problem: Vim9: not enough tests. Solution: Also run existing tests for Vim9 script. Make errors more consistent. https://github.com/vim/vim/commit/f47c5a8e2d8eda7c2c8a9cccf9568eb56c03a0cf Co-authored-by: Bram Moolenaar <Bram@vim.org>
* vim-patch:partial:8.2.3335: Vim9: not enough tests run with Vim9zeertzjq2023-06-12
| | | | | | | | | | | | | | | Problem: Vim9: not enough tests run with Vim9. Solution: Run a few more tests in Vim9 script and :def function. Fix that items(), keys() and values9) return zero for a NULL dict. Make join() return an empty string for a NULL list. Make sort() return an empty list for a NULL list. https://github.com/vim/vim/commit/ef98257593a0abf1300d0f70358dc45a70a62580 Skip f_reverse() change for consistency with other functions. Skip Test_null_list() and Test_null_dict() because of missing patches. Co-authored-by: Bram Moolenaar <Bram@vim.org>
* vim-patch:8.2.3202: Vim9: tests are only executed for legacy scriptzeertzjq2023-06-12
| | | | | | | | | Problem: Vim9: tests are only executed for legacy script. Solution: Run more tests also for Vim9 script. Fix uncovered problems. https://github.com/vim/vim/commit/5dd839ce20466eea52e59ecf86456f1ab370d2bd Co-authored-by: Bram Moolenaar <Bram@vim.org>
* vim-patch:8.2.3191: Vim9: not enough code is testedzeertzjq2023-06-12
| | | | | | | | | | Problem: Vim9: not enough code is tested. Solution: Use CheckLegacyAndVim9Success() in more places. Fix uncovered problems. https://github.com/vim/vim/commit/63cb6567f0153c35dc75cbc09039ff5d0a7b60e3 Co-authored-by: Bram Moolenaar <Bram@vim.org>
* test(unit/eval/typval_spec): adjust for Float to String conversionSean Dewar2023-06-12
| | | | | | | | | Adjust relevant Lua tests. Refactor testing logic for tv_get_string_* functions into test_string_fn(). Note that vim_snprintf(), which is used for stringifying floats, always calls xfree(tofree), even if tofree is NULL, so we need to expect that in the alloc log.
* vim-patch:8.2.2949: tests failing because no error for float to string ↵zeertzjq2023-06-12
| | | | | | | | | | | | | conversion Problem: Tests failing because there is no error for float to string conversion. Solution: Change the check for failure to check for correct result. Make some conversions strict in Vim9 script. https://github.com/vim/vim/commit/3cfa5b16b06bcc034f6de77070fa779d698ab5e9 Co-authored-by: Bram Moolenaar <Bram@vim.org>
* test(unit/eval/typval_spec): don't dereference NULL last_msg_histSean Dewar2023-06-12
| | | | | If last_msg_hist is NULL, check_emsg will cause the running test process to SIGSEGV from trying to access the msg member.
* vim-patch:8.2.2948: substitute() accepts a number but not a float expressionSean Dewar2023-06-12
| | | | | | | | | | | | | | | | | | Problem: Substitute() accepts a number but not a float expression. Solution: Also accept a float. (closes vim/vim#8331) https://github.com/vim/vim/commit/7a2217bedd223df4c8bbebe731bf0b5fe8532533 Vim9script is N/A. No need to port the strict argument and tv_get_string_buf_chk_strict(), as it's only used for Vim9script. Like the patch, use vim_snprintf over snprintf, as the "%g" specifier in snprintf removes the ".0" from integer floats. This means similiar to numbers, floats are (mostly) convertable to strings. Co-authored-by: Bram Moolenaar <Bram@vim.org>
* vim-patch:8.2.1524: no longer get an error for string concatenation with floatSean Dewar2023-06-12
| | | | | | | | | | | | | | Problem: No longer get an error for string concatenation with float. (Tsuyoshi Cho) Solution: Only convert float for Vim9 script. (closes vim/vim#6787) https://github.com/vim/vim/commit/2e0866128b6266829a7f38733d5188bc4ec68745 Vim9script is N/A. Required for v8.2.2949. Co-authored-by: Bram Moolenaar <Bram@vim.org>
* test(old): reorder test_substitute.vim to match upstream (#23994)zeertzjq2023-06-12
|
* feat: tostring(vim.version())Justin M. Keyes2023-06-12
| | | | | | | | | | Problem: tostring(vim.version()) returns "table: 0x…". Solution: Modify vim.version() to return a string prerelease instead of a boolean. Fix #23863
* feat: report "build" in vim.version() #23925treatybreaker2023-06-11
| | | | | | | | | | Problem: Nvim version string typically has a "build" component but vim.version() doesn't report it. Solution: Add the "build" field to vim.version(). Closes #23863
* fix(remote): restore previous --remote-expr output formatting (#23988)zeertzjq2023-06-11
| | | | - Use tostring() as that's what print() uses internally. - Do not append trailing new line.
* feat(lsp): add handlers for inlay hints (#23736)Chinmay Dalal2023-06-11
| | | initial support; public API left for a follow-up PR
* fix(remote): make --remote-expr print to stdout (#23980)zeertzjq2023-06-11
|
* fix(helptags): make multibyte help tags work properly (#23975)zeertzjq2023-06-11
|
* vim-patch:9.0.1626: Visual area not shown when using 'showbreak' (#23978)zeertzjq2023-06-11
| | | | | | | | | | Problem: Visual area not shown when using 'showbreak' and start of line is not visible. (Jaehwang Jung) Solution: Adjust "fromcol" for the space taken by 'showbreak'. (closes vim/vim#12514) https://github.com/vim/vim/commit/f578ca2c8f36b61ac3301fe8b59a8473c964cdc2 Co-authored-by: Bram Moolenaar <Bram@vim.org>