aboutsummaryrefslogtreecommitdiff
path: root/test
Commit message (Collapse)AuthorAge
* chore: fix typos (#16361)dundargoc2021-11-27
| | | | | | | | | | | | | | | | | | | | | | | | | | Co-authored-by: Brede Yabo Sherling Kristensen <bredeyabo@hotmail.com> Co-authored-by: zeertzjq <zeertzjq@outlook.com> Co-authored-by: István Donkó <istvan.donko@gmail.com> Co-authored-by: Julian Berman <Julian@GrayVines.com> Co-authored-by: bryant <bryant@users.noreply.github.com> Co-authored-by: Michael Lingelbach <m.j.lbach@gmail.com> Co-authored-by: nlueb <9465658+nlueb@users.noreply.github.com> Co-authored-by: Leonhard Saam <leonhard.saam@yahoo.com> Co-authored-by: Jesse Wertheim <jaawerth@gmail.com> Co-authored-by: dm1try <me@dmitry.it> Co-authored-by: Jakub Łuczyński <doubleloop@o2.pl> Co-authored-by: Louis Lebrault <louis.lebrault@gmail.com> Co-authored-by: Brede Yabo Sherling Kristensen <bredeyabo@hotmail.com> Co-authored-by: zeertzjq <zeertzjq@outlook.com> Co-authored-by: István Donkó <istvan.donko@gmail.com> Co-authored-by: Julian Berman <Julian@GrayVines.com> Co-authored-by: bryant <bryant@users.noreply.github.com> Co-authored-by: Michael Lingelbach <m.j.lbach@gmail.com> Co-authored-by: nlueb <9465658+nlueb@users.noreply.github.com> Co-authored-by: Leonhard Saam <leonhard.saam@yahoo.com> Co-authored-by: Jesse Wertheim <jaawerth@gmail.com> Co-authored-by: dm1try <me@dmitry.it> Co-authored-by: Jakub Łuczyński <doubleloop@o2.pl> Co-authored-by: Louis Lebrault <louis.lebrault@gmail.com>
* fix(lua): fix vim.deepcopy for metatables & cycled tables (#16435)Shadman2021-11-26
| | | | | vim.deepcopy previously didn't retain metatables in copies and caused stackoverflow on recursive tables/cycled tables this fixes these issues
* test(diagnostic): uncomment equality checkGregory Anders2021-11-24
|
* fix(fileio): replace characters over INT_MAX with U+FFFD (#16354)Javier Lopez2021-11-23
| | | | fixes #11877 credit: @zubairabid https://github.com/neovim/neovim/pull/12010
* Merge pull request #16402 from clason/treesitter-bumpChristian Clason2021-11-23
|\ | | | | build(deps): bump tree-sitter,treesitter-c to v0.20.1 and adapt tests
| * fix(tests): adapt parser_spec test to tree-sitter bumpChristian Clason2021-11-23
| | | | | | | | | | Change query to include anonymous nodes (`(_)` -> `[_]`) and use new syntax (`{vim,lua}.match?`->`#{vim,lua}.match?`)
* | fix(diagnostic): resolve buffer number in get() (#16407)Gregory Anders2021-11-22
| |
* | fix(diagnostics): don't allow 0 bufnr for metatable index (#16405)Gregory Anders2021-11-22
|/ | | | | | | | | | | | | | | | | | | | 04bfd20bb introduced a subtle bug where using 0 as the buffer number in the diagnostic cache resets the cache for the current buffer. This happens because we were not checking to see if the _resolved_ buffer number already existed in the cache; rather, when the __index metamethod was called we assumed the index did not exist so we set its value to an empty table. The fix for this is to check `rawget()` for the resolved buffer number to see if the index already exists. However, the reason this bug was introduced in the first place was because we are simply being too clever by allowing a 0 buffer number as the index which is automatically resolved to a real buffer number. In the interest of minimizing metatable magic, remove this "feature" by requiring the buffer number index to always be a valid buffer. This ensures that the __index metamethod is only ever called for non-existing buffers (which is what we wanted originally) as well as reduces some of the cognitive overhead for understanding how the diagnostic cache works. The tradeoff is that all public API functions must now resolve 0 buffer numbers to the current buffer number.
* Merge pull request #16341 from zeertzjq/vim-8.2.2518nightlyJan Edmund Lazo2021-11-21
|\ | | | | vim-patch:8.2.{2518,2520,3572,3588}: 'listchars' (and 'fillchars'?) fixes
| * fix(options): using :set fillchars should clear local valuezeertzjq2021-11-17
| |
| * vim-patch:8.2.2518: 'listchars' should be window-localzeertzjq2021-11-17
| | | | | | | | | | | | | | | | | | | | | | Problem: 'listchars' should be window-local. Solution: Make 'listchars' global-local. (Yegappan Lakshmanan, Marco Hinz, closes vim/vim#5206, closes vim/vim#7850) https://github.com/vim/vim/commit/eed9d46293f0842aad0d50ff3a526f9a48b12421 Nvim already has this feature, but it implements :set listchars the same as :setglobal listchars, which is incorrect. Vim's implementation of :set listchars is correct: using :set listchars clears local value.
* | fix(diagnostic): remove invalid buffers from cache (#16397)smolck2021-11-21
| | | | | | | | | | | | | | | | | | Errors were being caused by invalid buffers being kept around in diagnostic_cache, so add a metatable to diagnostic_cache which attaches to new buffers in the cache, removing them after they are invalidated. Closes #16391. Co-authored-by: Gregory Anders <8965202+gpanders@users.noreply.github.com>
* | Merge pull request #16362 from zeertzjq/vim-8.2.3617Jan Edmund Lazo2021-11-21
|\ \ | | | | | | vim-patch:8.2.{3468,3617,3618,3622}: some other CWD related patches
| * | vim-patch:8.2.3622: "verbose pwd" shows confusing infozeertzjq2021-11-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: "verbose pwd" shows confusing info when :lcd does not change directory. Solution: Clear last_chdir_reason also when the directory does not change. (closes vim/vim#9160) https://github.com/vim/vim/commit/64be6aa3a54ecfe355d4a03e1200650c301e7f29 This only ports the tests, as this is already Nvim's behavior.
| * | vim-patch:8.2.3618: getcwd() is unclear about how 'autochdir' is usedzeertzjq2021-11-19
| | | | | | | | | | | | | | | | | | | | | Problem: getcwd() is unclear about how 'autochdir' is used. Solution: Update the help for getcwd(). Without any arguments always return the actual current directory. (closes vim/vim#9142) https://github.com/vim/vim/commit/851c7a699ae00bdc14a4db874cf722b7b7393b53
| * | vim-patch:8.2.3617: ":verbose pwd" does not mention 'autochdir' was appliedzeertzjq2021-11-19
| | | | | | | | | | | | | | | | | | Problem: ":verbose pwd" does not mention 'autochdir' was applied. Solution: Remember the last chdir was done by 'autochdir'. (issue vim/vim#9142) https://github.com/vim/vim/commit/0526815c15170a5926e1008600ec29d42d8b64c2
| * | vim-patch:8.2.3468: problem with :cd when editing file in non-existent directoryzeertzjq2021-11-19
| | | | | | | | | | | | | | | | | | | | | Problem: Problem with :cd when editing file in non-existent directory. (Yee Cheng Chin) Solution: Prepend the current directory to get the full path. (closes vim/vim#8903) https://github.com/vim/vim/commit/c6376c798433bcb9ee38a8664299d11454546950
* | | Merge pull request #16370 from gpanders/diagnostic-column-clampGregory Anders2021-11-21
|\ \ \
| * | | fix(diagnostic): fix navigation with diagnostics placed past end of lineGregory Anders2021-11-19
| | | |
| * | | fix(diagnostic): deepcopy diagnostics before clamping line numbersGregory Anders2021-11-19
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The current 'clamp_line_numbers' implementation modifies diagnostics in place, which can have adverse downstream side effects. Before clamping line numbers, make a copy of the diagnostic. This commit also merges the 'clamp_line_numbers' method into a new 'get_diagnostics' local function which also implements the more general "get" method. The public 'vim.diagnostic.get()' API now just uses this function (without clamping). This has the added benefit that other internal API functions that need to use get() no longer have to go through vim.validate. Finally, reorganize the source code a bit by grouping all of the data structures together near the top of the file.
* | | chore(lsp): clean up initialization process (#16369)Michael Lingelbach2021-11-21
| | | | | | | | | | | | | | | * send vim.NIL instead of not sending workspaceFolders * read fallback rootPath and rootUri from workspaceFolders * update documentation
* | | fix: remove unneeded gzip checkShougo Matsushita2021-11-19
| | |
* | | fix: shell problemShougo Matsushita2021-11-19
| | |
* | | fix: fix GZIP errorShougo Matsushita2021-11-19
| | |
* | | fix: remove previous executed directories to execute tests locallyShougo Matsushita2021-11-19
|/ /
* / fix(lsp): improve incremental sync robustness (#16358)Michael Lingelbach2021-11-18
|/ | | | | closes https://github.com/neovim/neovim/issues/16352 * improve handling of multi-byte deletions
* Merge pull request #16328 from gpanders/diagnostic-prefix-hiGregory Anders2021-11-16
|\
| * refactor(diagnostic)!: rename 'show_header' to 'header'Gregory Anders2021-11-15
| | | | | | | | | | | | Rename the `show_header` option in `open_float` to simply `header` and allow users to specify both the header string as well as the highlight group.
| * feat(diagnostic): allow 'prefix' option to return highlightGregory Anders2021-11-15
| | | | | | | | | | Extend the 'prefix' option for `open_float` to also provide an optional highlight group for the prefix string.
* | refactor(diagnostic): make bufnr arguments consistent (#16323)Gregory Anders2021-11-16
| | | | | | | | | | | | | | Make the bufnr argument have similar semantics across API functions; namely, a nil value means "all buffers" while 0 means "current buffer". This increases the flexibility of the API by allowing functions such as enable() and disable() to apply globally or per-namespace, rather than only on a specific buffer.
* | fix(lsp): fix edge cases in incremental sync (#16308)Michael Lingelbach2021-11-15
|/
* feat(diagnostic): add 'prefix' option to open_float (#16321)Gregory Anders2021-11-14
| | | | The 'prefix' option accepts a function or a string that is used to add a prefix string to each diagnostic displayed in the floating window.
* fix(lsp): ensure buffers are re-attached on rename (#16266)Mathias Fußenegger2021-11-14
| | | | | | | | | If a LSP server sent a workspace edit containing a rename the buffers file name changed without the server receiving a close notification for the old buffer and without the client properly re-attaching on the new file. This affected `Move` code-actions in nvim-jdtls, but also `vim.lsp.buf.rename` on a class level.
* fix(float): skip non-focusable windows for :windo (#15378)Daniel Steinberg2021-11-11
|
* test: add tests for freeing channel opened by termopen()zeertzjq2021-11-11
| | | | This indirectly covers #16264
* fix(channel): fix channels opened by nvim_open_term() never being freedzeertzjq2021-11-11
|
* fix(channel): throw error if sending to internal channel w/o terminalzeertzjq2021-11-11
| | | | | Prevent SIGABRT when sending to a channel created by nvim_open_term() after the associated terminal has been deleted.
* fix(lsp): rewrite incremental sync (#16252)Michael Lingelbach2021-11-09
| | | | | | * use codeunits/points instead of byte ranges when applicable * take into account different file formats when computing range and sending text (dos, unix, and mac supported) * add tests of incremental sync
* feat(diagnostic): do not require namespace for hide() and show() (#16261)Gregory Anders2021-11-09
| | | | | | | Also fix a few other small bugs regarding saving and restoring extmarks. In particular, now that the virtual text and underline handlers have their own dedicated namespaces, they should be responsible for saving and restoring their own extmarks. Also fix the wrong argument ordering in the call to `clear_diagnostic_cache` in the `on_detach` callback.
* feat(ui): add vim.ui.input and use in lsp rename (#15959)Sebastian Lyng Johansen2021-11-07
| | | | | | * vim.ui.input is an overridable function that prompts for user input * take an opts table and the `on_confirm` callback, see `:help vim.ui.input` for more details * defaults to a wrapper around vim.fn.input(opts) * switches the built-in client's rename handler to use vim.ui.input by default
* Merge pull request #16155 from zeertzjq/fix-redr-border-corruptionBjörn Linse2021-11-06
|\ | | | | fix(float): fix potential heap corruption in win_redr_border
| * fix(float): redraw if w_border_adj changedzeertzjq2021-10-28
| |
| * fix(float): fix potential heap corruption in win_redr_borderzeertzjq2021-10-28
| |
* | feat(lua): enable stack traces in error output (#16228)Gregory Anders2021-11-06
| |
* | fix(input): never reinterpret unmapped ALT- chrods in Terminal mode (#16222)zeertzjq2021-11-04
| |
* | fix(diagnostic): fix option resolution in open_float (#16229)Gregory Anders2021-11-04
| |
* | fix(extmark): fix missing virt_lines when using id param of set_extmarkBjörn Linse2021-11-01
| |
* | refactor(api/marks)!: add opts param for feature extensibility (#16146)Javier Lopez2021-11-01
| | | | | | | | | | In the future we might want to extend the concept of named marks and adding opts reduces the need of changing the function signature in the furute.
* | feat(lsp): add per-client commands (#16101)Michael Lingelbach2021-11-01
| |
* | fix(runtime): fix missing packpath entriesBjörn Linse2021-10-31
| |