aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
...
* Merge pull request #23352 from zeertzjq/pum-at-cursorzeertzjq2023-04-28
|\ | | | | fix(pum): make :popup position correctly with float border
| * vim-patch:9.0.1493: popup menu position wrong in window with toolbarzeertzjq2023-04-28
| | | | | | | | | | | | | | | | | | | | Problem: Popup menu position wrong in window with toolbar. Solution: Take the window toolbar into account when positioning the popup menu. (closes vim/vim#12308) https://github.com/vim/vim/commit/4e1ca0d9a6c6d66987da67155e97f83f286ffbcc Fixed in the previous commit. Test only.
| * fix(pum): make :popup position correctly with float borderzeertzjq2023-04-28
|/
* Merge pull request #23356 from ii14/fix/23355bfredl2023-04-27
|\ | | | | fix(events): null dereference in autocmd functions
| * fix(events): null dereference in autocmd functionsii142023-04-27
| |
* | ci: replace stale bot with custom implementationdundargoc2023-04-27
|/ | | | The stale action has a bug where it won't close an issue/PR if it has comments after the stale label.
* perf(events): store autocommands in flat vectors (#23256)ii142023-04-27
| | | | | | | | | | Instead of nested linked lists, store autocommands in a flat, contiguous kvec_t, with one kvec_t per event type. Previously patterns were stored in each node of the outer linked list, so they can be matched only once on repeating patterns. They are now reference counted and referenced in each autocommand, and matching is skipped if the pattern repeats. Speeds up creation and deletion, execution is not affected. Co-authored-by: ii14 <ii14@users.noreply.github.com>
* fix: disallow removing extmarks in on_lines callbacks (#23219)Lewis Russell2023-04-27
| | | | | | | | | | fix(extmarks): disallow removing extmarks in on_lines callbacks decor_redraw_start (which runs before decor_providers_invoke_lines) gets references for the extmarks on a specific line. If these extmarks are deleted in on_lines callbacks then this results in a heap-use-after-free error. Fixes #22801
* vim-patch:9.0.1492: using uninitialized memory when argument is missing (#23351)zeertzjq2023-04-28
| | | | | | | | | Problem: Using uninitialized memory when argument is missing. Solution: Check there are sufficient arguments before the base. (closes vim/vim#12302) https://github.com/vim/vim/commit/b7f2270bab102d68f83a6300699b7f98efad81f2 Co-authored-by: Bram Moolenaar <Bram@vim.org>
* fix(pum): position properly with ext_multigrid (#23336)zeertzjq2023-04-27
|
* docs(lsp): remove obsolete lsp-extension example (#23346)Christian Clason2023-04-27
| | | | This example is made obsolete by the addition of `vim.lsp.start()` and `vim.fs` (whose use is already documented in `:h lsp-quickstart`).
* Merge pull request #23216 from bfredl/lpegbfredl2023-04-27
|\ | | | | refactor(build): include lpeg as a library
| * refactor(build): include lpeg as a librarybfredl2023-04-27
| |
* | test: fix dependencies between test cases (#23343)zeertzjq2023-04-27
| | | | | | Discovered using --shuffle argument of busted.
* | build: remove BUSTED_PRG dead code (#23340)zeertzjq2023-04-27
| | | | | | BUSTED_PRG is no longer used by RunTests.cmake.
* | build(Makefile): add nvim to oldtest phony targetluukvbaal2023-04-27
| | | | | | This is to force a rebuild each time a file is changed.
* | vim-patch:9.0.1491: wrong scrolling with ls=0 and :botright split (#23333)zeertzjq2023-04-27
| | | | | | | | | | | | Problem: Wrong scrolling with ls=0 and :botright split. Solution: Add statusline before calling frame_new_height(). (closes vim/vim#12299) https://github.com/vim/vim/commit/fbf2071ac9ef08302a1df86c15f3d4ddbe871243
* | refactor: uncrustifydundargoc2023-04-26
| | | | | | | | Notable changes: replace all infinite loops to `while(true)` and remove `int` from `unsigned int`.
* | ci: containerize the external dependencies testdundargoc2023-04-26
| | | | | | | | | | | | Cirrus ci automatically pushes/caches docker images, which makes containerization much simpler to handle. Moving this job to cirrus ci shortens the job by a minute, and reduces github actions CI usage by two minutes per PR.
* | refactor(clang-tidy): remove redundant castsdundargoc2023-04-26
| |
* | ci: update reviewersdundargoc2023-04-26
| |
* | build(clint): fix deprecation and linter warningsdundargoc2023-04-26
| | | | | | `sre_compile` is deprecated in python 11, and gives warning when is used.
* | Merge pull request #23288 from MunifTanjim/issue-22263zeertzjq2023-04-27
|\ \ | |/ |/| fix(normal): fix repeated trigger modechanged for scheduled callback
| * test: scheduled callback shouldn't trigger ModeChanged repeatedlyMunif Tanjim2023-04-26
| |
| * vim-patch:9.0.1490: the ModeChanged event may be triggered too oftenzeertzjq2023-04-26
|/ | | | | | | | Problem: The ModeChanged event may be triggered too often. Solution: Only trigger ModeChanged when no operator is pending. (closes vim/vim#12298) https://github.com/vim/vim/commit/73916bac5ac2a054a0c71adfe8d742691cdfd95c
* Merge pull request #23308 from bfredl/fs_time_boogalobfredl2023-04-26
|\ | | | | refactor(fs): IT'S TIME: get rid of fs_loop and fs_loop_mutex
| * refactor(fs): now it is time to get rid of fs_loop and fs_loop_mutexbfredl2023-04-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Here's the headline: when run in sync mode (last argument cb=NULL), these functions don't actually use the uv_loop_t. An earlier version of this patch instead replaced fs_loop with using main_loop.uv on the main thread and luv_loop() on luv worker threads. However this made the code more complicated for no reason. Also arbitrarily, half of these functions would attempt to handle UV_ENOMEM by try_to_free_memory(). This would mostly happen on windows because it needs to allocate a converted WCHAR buffer. This should be a quite rare situation. Your system is pretty much hosed already if you cannot allocate like 50 WCHAR:s. Therefore, take the liberty of simply removing this fallback. In addition, we tried to "recover" from ENOMEM in read()/readv() this way which doesn't make any sense. The read buffer(s) are already allocated at this point. This would also be an issue when using these functions on a worker thread, as try_to_free_memory() is not thread-safe. Currently os_file_is_readable() and os_is_dir() is used by worker threads (as part of nvim__get_runtime(), to implement require from 'rtp' in threads). In the end, these changes makes _all_ os/fs.c functions thread-safe, and we thus don't need to document and maintain a thread-safe subset.
* | build: revert accidental permission changes (#23319)zeertzjq2023-04-26
| | | | | | Revert the permission changes in 794d2744f33562326172801ddd729853e7135347.
* | vim-patch:9.0.1485: no functions for converting from/to UTF-16 index (#23318)zeertzjq2023-04-26
| | | | | | | | | | | | | | | | | | Problem: no functions for converting from/to UTF-16 index. Solution: Add UTF-16 flag to existing funtions and add strutf16len() and utf16idx(). (Yegappan Lakshmanan, closes vim/vim#12216) https://github.com/vim/vim/commit/67672ef097dd708244ff042a8364994da2b91e75 Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
* | vim-patch:8.2.3314: behavior of exists() in a :def function is unpredictable ↵zeertzjq2023-04-26
| | | | | | | | | | | | | | | | | | | | (#23317) Problem: Behavior of exists() in a :def function is unpredictable. Solution: Add exists_compiled(). https://github.com/vim/vim/commit/267359902c8792fed13543ddeb56c6df0ae74957 Co-authored-by: Bram Moolenaar <Bram@vim.org>
* | vim-patch:8.2.3139: functions for string manipulation are spread out (#23316)zeertzjq2023-04-26
| | | | | | | | | | | | | | | | | | Problem: Functions for string manipulation are spread out. Solution: Move string related functions to a new source file. (Yegappan Lakshmanan, closes vim/vim#8470) https://github.com/vim/vim/commit/a2438132a675be4dde3acbdf03ba1fdb2f09427c Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
* | vim-patch:partial:9.0.0359: error message for wrong argument type is not ↵zeertzjq2023-04-25
| | | | | | | | | | | | | | | | | | | | | | | | | | specific (#23315) Problem: Error message for wrong argument type is not specific. Solution: Include more information in the error. (Yegappan Lakshmanan, closes vim/vim#11037) https://github.com/vim/vim/commit/8deb2b30c77035bb682ccf80b781455ac1d6038b Skip reduce() and deepcopy() changes because of missing patches. Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
* | vim-patch:9.0.0875: using freed memory when executing delfunc at more prompt ↵zeertzjq2023-04-25
| | | | | | | | | | | | | | | | | | | | (#23314) Problem: Using freed memory when executing delfunc at the more prompt. Solution: Check function list not changed in another place. (closes vim/vim#11437) https://github.com/vim/vim/commit/398a26f7fcd58fbc6e2329f892edbb7479a971bb Co-authored-by: Bram Moolenaar <Bram@vim.org>
* | Merge pull request #23303 from gpanders/more-vim-iterGregory Anders2023-04-25
|\ \ | | | | | | Create iter_spec and vim.iter module
| * | refactor(iter): move helper functions under vim.iterGregory Anders2023-04-25
| | | | | | | | | | | | vim.iter is now both a function and a module (similar to vim.version).
| * | test: move vim.iter tests to separate fileGregory Anders2023-04-24
| | |
* | | feat(lua): vim.keycode (#22960)ii142023-04-25
| | | | | | | | | | | | | | | | | | Using nvim_replace_termcodes is too verbose, add vim.keycode for translating keycodes. Co-authored-by: ii14 <ii14@users.noreply.github.com>
* | | Merge pull request #23313 from zeertzjq/vim-8.2.3768zeertzjq2023-04-25
|\ \ \ | | | | | | | | vim-patch:8.2.{3768,3772}
| * | | vim-patch:8.2.3772: timer info test fails on slow machinezeertzjq2023-04-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: Timer info test fails on slow machine. Solution: Use WaitForAssert(). https://github.com/vim/vim/commit/ff39a650b2bd31e30d1bb8766e8560f9a14a7137 Co-authored-by: Bram Moolenaar <Bram@vim.org>
| * | | vim-patch:8.2.3768: timer_info() has the wrong repeat value in a timer callbackzeertzjq2023-04-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: timer_info() has the wrong repeat value in a timer callback. Solution: Do not add one to the repeat value when in the callback. (closes vim/vim#9294) https://github.com/vim/vim/commit/95b2dd0c008f0977ebb3cbe233a5064001a332e1 Co-authored-by: Bram Moolenaar <Bram@vim.org>
| * | | fix(timer): allow timer_info() to get info about current timerzeertzjq2023-04-25
|/ / /
* | | vim-patch:8.2.5019: cannot get the first screen column of a character (#23312)zeertzjq2023-04-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: Cannot get the first screen column of a character. Solution: Let virtcol() optionally return a list. (closes vim/vim#10482, closes vim/vim#7964) https://github.com/vim/vim/commit/0f7a3e1de6f71e8e1423fe594890d6aa7f94e132 Co-authored-by: LemonBoy <thatlemon@gmail.com>
* | | vim-patch:9.0.0335: checks for Dictionary argument often give a vague error ↵zeertzjq2023-04-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (#23309) Problem: Checks for Dictionary argument often give a vague error message. Solution: Give a useful error message. (Yegappan Lakshmanan, closes vim/vim#11009) https://github.com/vim/vim/commit/04c4c5746e15884768d2cb41370c3276a196cd4c Cherry-pick removal of E922 from docs from patch 9.0.1403. Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
* | | refactor: remove unnecessary height change in frame_add_hsep() (#23305)zeertzjq2023-04-25
| |/ |/| | | | | This height change is wrong, and the height will be overwritten later by another height change.
* | Merge pull request #23293 from bfredl/bigsleepbfredl2023-04-25
|\ \ | | | | | | refactor(time): refactor delay with input checking
| * | refactor(time): refactor delay with input checkingbfredl2023-04-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, there were three low-level delay entry points - os_delay(ms, ignoreinput=true): sleep for ms, only break on got_int - os_delay(ms, ignoreinput=false): sleep for ms, break on any key input os_microdelay(us, false): equivalent, but in μs (not directly called) - os_microdelay(us, true): sleep for μs, never break. The implementation of the latter two both used uv_cond_timedwait() This could have been for two reasons: 1. allow another thread to "interrupt" the wait 2. uv_cond_timedwait() has higher resolution than uv_sleep() However we (1) never used the first, even when TUI was a thread, and (2) nowhere in the codebase are we using μs resolution, it is always a ms multiplied with 1000. In addition, os_delay(ms, false) would completely block the thread for 100ms intervals and in between check for input. This is not how event handling is done alound here. Therefore: Replace the implementation of os_delay(ms, false) to use LOOP_PROCESS_EVENTS_UNTIL which does a proper epoll wait with a timeout, instead of the 100ms timer panic. Replace os_microdelay(us, false) with a direct wrapper of uv_sleep.
* | | fix(statusline): also allow right click when 'mousemodel' is "popup*" (#23258)luukvbaal2023-04-25
| |/ |/| | | | | | | Problem: The 'statusline'-format ui elements do not receive right click events when "mousemodel" is "popup*" Solution: Do not draw popupmenu and handle click event instead.
* | fix(column): don't reset 'statuscolumn' width after it has been drawnluukvbaal2023-04-24
| | | | | | | | | | | | | | | | Problem: 'statuscolumn' width may be reset after it has been drawn when multiple windows contain the same buffer. This results in an offset for the drawn cursor position. Solution: Loop over all windows (twice) prior to drawing them to reset the 'statuscolumn' width and validate the sign column when necessary.
* | fix(pum): show right-click menu above cmdline area (#23298)zeertzjq2023-04-24
| |
* | build: add "ci" configure preset to reduce verbositydundargoc2023-04-23
| | | | | | | | | | | | | | | | | | | | `cmake --preset ci` is equivalent to `cmake -B build -G Ninja -D CI_BUILD=ON` Also remove build presets as they're not very useful without workflow presets, which are only available in schema versions 6 and above.