| Commit message (Collapse) | Author | Age |
|
|
|
|
|
| |
Problem: Cannot use a lambda with quickfix functions.
Solution: Add support for lambda. (Yegappan Lakshmanan, closes vim/vim#6499)
https://github.com/vim/vim/commit/d43906d2e5969288f239df851f5ad7b1dc2c7251
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: Code to handle callbacks is duplicated.
Solution: Add callback_T and functions to deal with it.
https://github.com/vim/vim/commit/3a97bb3f0f8bd118ae23f1c97e55d84ff42eef20
Port Vim's put_callback() as callback_put()
because Neovim's naming convention is {type}_{action},
not {action}_{type}.
Renaming put_callback type as PutCallback.
https://neovim.io/develop/style-guide.xml#Type_Names
|
|\
| |
| | |
fix(runtime): Fix bugs regarding lua runtime files
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
It's happening because do_source is only expected to return FAIL when it
was unable to open file . But `nlua_exec_file` returns fail for parsing
and execution error too . Those errors are emitted through `nlua_error`.
So now return value of nlua_exec_file is ignored like do_cmdline. It now
only returns fail when it was unable to open file that check is done
before calling nlua_exec_file or do_cmdline. Errors in nlua_exec_file
are still directly emitted through nlua_error like before.
|
| |
| |
| |
| |
| |
| |
| | |
When a keymap is set from lua currently verbose message says
it's set from line 1. That's incorrect because we don't really know when
it was set. So until proper :verbose support isn't added for sourceing
lua it shouldn't say where it was set at.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
As per #14236, performing extmark cleanup in a certain namespace does
not guarantee removing all the extmarks inside given namespace.
The issue resides within the tree node removal method and results in
a couple of rare edge cases.
To demonstrate what causes this bug, I'll give an example covering one
of the edge cases.
=== AN EXAMPLE ===
(A) (B) (C) (D) (E)
--------- --------- --------- --------- ---------
<0, 1> <0, 1> <0, 1> <0, 1> <0, 1>
<0, 2> <0, 2> <0, 2> <0, 2> <0, 2>
<0, 3> <0, 3> <0, 3> <0, 3> <0, 3>
<0, 4> <0, 4> <0, 4> <0, 4> <0, 4>
<0, 5> <0, 5> <0, 5> <0, 5> <0, 5>
<0, 6> <0, 6> <0, 6> <0, 6> <0, 6>
<0, 7> <0, 7> <0, 7> <0, 7> <0, 7>
<0, 8> <0, 8> <0, 8> <0, 8> <0, 8>
<0, 9> <0, 9> * * <0, 9> * <0, 9>
[0, 10] * [0, 10] <0, 9> [0, 11] [0, 11]
[0, 11] [0, 11] [0, 11] [0, 12] [0, 12] *
[0, 12] [0, 12] [0, 12] [0, 13] [0, 13]
[0, 13] [0, 13] [0, 13] [0, 14] [0, 14]
[0, 14] [0, 14] [0, 14] [0, 15] [0, 15]
[0, 15] [0, 15] [0, 15] [0, 16] [0, 16]
[0, 16] [0, 16] [0, 16] [0, 17] [0, 17]
[0, 17] [0, 17] [0, 17] [0, 18] [0, 18]
[0, 18] [0, 18] [0, 18] [0, 19] [0, 19]
[0, 19] [0, 19] [0, 19] [0, 20] [0, 20]
[0, 20] [0, 20] [0, 20]
DIAGRAM EXPLANATION
* Every column is a state of the marktree at a certain stage.
* To make it simple, I don't draw the whole tree. What you see are
2 leftmost parent nodes ([0, 10], [0, 20]) and their children placed
in order `MarkTreeIter` would iterate through. From top to bottom.
* Numbers on this diagram represent extmark coordinates. Relative
positioning and actual mark IDs used by the marktree are avoided
for simplicity.
* 2 types of brackets around coordinates represent 2 different
extmark namespaces (`ns_id`s).
* '*' shows iterator position.
ACTUAL EXPLANATION
Let's assume, we have two sets of extmarks from 2 different plugins:
* Plugin1: <0, 1-9>
* Plugin2: [0, 10-20]
1. Plugin2 calls
`vim.api.nvim_buf_clear_namespace(buf_handle, ns_id, 0, -1)`
to clear all its extmarks which results in `extmark_clear` call.
2. The iteration process goes on ignoring extmarks with irrelevant
`ns_id` from Plugin1, until it reaches [0, 10], entering state (A).
3. At the end of cleaning up process, `marktree_del_itr` gets called.
This function is supposed to remove given node and, if necessary,
restructure the tree. Also, move the iterator to the next node.
The bug occurs in this function.
4. The iterator goes backwards to the node's last child, to put it
in the place of its deleted parent later. (B)
5. The parent node is deleted and replaced with its child node. (C)
6. Since now this node has 8 children, which is less than
`MT_BRANCH_FACTOR - 1`, it get's merged with the next node. (D)
7. Finally, since at (B) the iterator went backward, it goes forward
twice, skipping [0, 11] node, causing this extmark to persist,
causing the bug. (E)
ANALYSIS AND SOLUTION
The algorithm works perfectly when the parent node gets replaced by
its child, but no merging occurs. I.e. the exact same diagram,
but without the (D) stage. If not for (D), it would iterate to <0, 9>
and then to [0, 11]. So, iterating twice makes sense. The actual problem
is in (C) stage, because the iterator index isn't adjusted and still
pointing to no longer existent node. So my solution is to adjust
iterator index after removing the child node.
More info: https://github.com/neovim/neovim/pull/14719
|
|/
|
|
|
| |
Problem: Unreachable code.
Solution: Remove the code. (closes vim/vim#8406)
https://github.com/vim/vim/commit/2fb749568662c86992aea3b596458b9e470f223d
|
|\
| |
| | |
perf(extmarks): allow ephemeral extmarks past EOF to remove O(strlen^2) cost of tree-sitter
|
| | |
|
|/
|
|
|
|
|
|
|
| |
reversed (#14839)
Problem: When 'rightleft' is set the line number is sometimes drawn
reversed.
Solution: Adjust how space is handled. (Christian Brabandt, closes vim/vim#8389,
closes vim/vim#8391)
https://github.com/vim/vim/commit/29f0dc3689eafcf7888e06d57d1cf79e62c5c148
|
|\
| |
| | |
screen: fix typo in screen.c
|
| |
| |
| | |
accomodate -> accommodate
|
| |
| |
| | |
seperated -> separated
|
|\ \
| | |
| | | |
[RDY] feat(float): add rounded borders preset
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Add `borders = "rounded"` preset for `nvim_open_win`, equivalent to
border = {"╭", "─", "╮", "│", "╯", "─", "╰", "│"}
Also add undocumented "solid" preset to docs.
|
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Jupyter Notebook files are not recognized.
Solution: Recognize *.ipynb. (closes vim/vim#8375)
https://github.com/vim/vim/commit/2e66b0d1373891f40e2561ccd2d3369de1614bcd
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
style
Problem: Some terminals misinterpret the code for getting cursor style.
Solution: Send a sequence to the terminal and check the result. (IWAMOTO
Kouichi, closes vim/vim#2126) Merged with current code.
https://github.com/vim/vim/commit/a45551a53557dba98973fdb3ff737dea2fffcda3
Cherry-pick Test_cwindow_highlight() from patch v8.1.2040
because it is skipped.
|
|/ /
| |
| |
| |
| |
| | |
Problem: Test 59 is old style.
Solution: Convert into a new style test. (Yegappan Lakshmanan, closes vim/vim#6604)
https://github.com/vim/vim/commit/aa970abd0a987de96321d33db82f70bbceac931b
|
|\ \
| | |
| | | |
fixup(runtime): Fix lua runtime files not listed in :scriptnames
|
| | |
| | |
| | |
| | | |
This was init.lua will be logged in startuptime
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
lua runtime files weren't listed in :scriptname & profiler.
This fixes that.
* Add tests
* Small doc tweeks
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Spellfile functionality not fully tested.
Solution: Add tests for CHECKCOMPOUNDPATTERN and COMMON. (Dominique Pellé,
closes vim/vim#8270)
https://github.com/vim/vim/commit/dc3275a1ac73b6c4d0c9d2e238ea80b477705b6f
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Cannot use "z=" when 'spell' is off.
Solution: Make "z=" work even when 'spell' is off. (Christian Brabandt,
Gary Johnson, closes vim/vim#6227)
https://github.com/vim/vim/commit/152e79e94bb935e75b866bd55479648cde11066a
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Tests for spell suggestions are slow.
Solution: Use shorter words. Test with latin1 and utf-8 to cover more code.
(Dominique Pelle, closes vim/vim#5399)
https://github.com/vim/vim/commit/767340574b5a0c697e650b3bbc3a4af10e51cb89
|
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Memory access error when "z=" has no suggestions.
Solution: Check for negative index.
https://github.com/vim/vim/commit/569fea2c312126dd5a542c4b1aa51095136a2c0d
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Spell suggestions insufficiently tested.
Solution: Add spell suggestion tests. (Dominique Pelle, closes vim/vim#5398)
https://github.com/vim/vim/commit/e9a8d1f9adaf4599b5a7923f8db8e207ed6e7eca
Requires latest en.utf-8.spl from
https://ftp.nluug.nl/pub/vim/runtime/spell/.
Include the following patch because patch v8.2.0946 was merged:
vim-patch:8.2.0948: spell test fails
Problem: Spell test fails.
Solution: Adjust expected text of the prompt.
https://github.com/vim/vim/commit/d281b7c227bc4c78813fdc297ccee4b2cad7e605
|
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Spellrare and spellrepall in the wrong order.
Solution: Put spellrare below spellrepall. (closes vim/vim#4820)
https://github.com/vim/vim/commit/a3891681f72fd9efdea6444620d787358850d823
|
|/ /
| |
| |
| |
| |
| | |
Problem: There is :spellwrong and :spellgood but not :spellrare.
Solution: Add :spellrare. (Martin Tournoij, closes vim/vim#4291)
https://github.com/vim/vim/commit/08cc374dabd2a02785129fa1c0100f7745c244ad
|
| |
| |
| |
| | |
Refs #12985
|
|\ \
| | |
| | | |
vim-patch:8.2.{1702,2422,2966,2971,2974}
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Greek spell checking uses wrong case folding.
Solution: Fold capital sigma depending on whether it is at the end of a
word or not. (closes vim/vim#299)
https://github.com/vim/vim/commit/4f135275984722c1b1e9ace72eeeb7ce7e4ec983
|
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Cannot yank a block without trailing spaces.
Solution: Add the "zy" command. (Christian Brabandt, closes vim/vim#8292)
https://github.com/vim/vim/commit/544a38e44db0f25ec4fa7a2a4666cf28a2336f33
|
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Crash when deleting with line number out of range. (Houyunsong)
Solution: Avoid using a negative line number.
https://github.com/vim/vim/commit/1d859e24218635c57c09801840ff159cb845ae6a
|
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Crash when using undo after deleting folded lines.
Solution: Check for NULL pointer. (closes vim/vim#6968)
https://github.com/vim/vim/commit/da697645d5917eb3d4168c06c3442bef9fb746bf
|
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: ml_get errors after recovering a file. (Yegappan Lakshmanan)
Solution: Fix the cursor position after deleting lines.
https://github.com/vim/vim/commit/e3f50ad640fb30f27027f85a616280288bbc14ca
|
|\ \ \
| | | |
| | | | |
fix(lua): ensure vim.region truncates to buf range
|
| |/ /
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
If vim.region receives a large range outside of the current buffer
bounds, it will not check the range ahead of time and loop until neovim
exhausts the system memory.
Fixes #14743
|
|\ \ \
| | | |
| | | | |
runtime: allow to use .lua files for most features defined as &rtp/{feature}/*.vim
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
So now :source can run lua files too :)
* feat: Add support for :[ranged]source for lua files
|
| | | |
| | | |
| | | |
| | | | |
Enabled for `:colorscheme` `:compiler` filetype
|
| | | | |
|
| | | | |
|
| | | |
| | | |
| | | |
| | | | |
* tests(runtime): move runtime/plugin tests to functional/lua/runtime_spec
|
| |/ /
| | |
| | |
| | |
| | |
| | | |
For opt plugins these files are sourced on `:packadd`
* `:runtime` Now can exexute lua files
|
|/ / |
|
| | |
|
| | |
|
| | |
|
|\ \
| | |
| | | |
api: add nvim_win_call
|
| | | |
|