| Commit message (Collapse) | Author | Age |
... | |
| |/
| |
| |
| | |
Expand mappings first by calling `vpeekc()` directly.
|
| |
| |
| |
| |
| |
| |
| | |
Problem: curpos() does not accept a string argument as before.
solution: Make a string argument work again. (Yegappan Lakshmanan,
closes vim/vim#7690
https://github.com/vim/vim/commit/9ebcf231bdccc1673cc92b20f5190fc577ad29d0
|
| |
| |
| |
| |
| |
| |
| | |
Problem: Not easy to get mark en cursor posotion by character count.
Solution: Add functions that use character index. (Yegappan Lakshmanan,
closes vim/vim#7648)
https://github.com/vim/vim/commit/6f02b00bb0958f70bc15534e115b4c6dadff0e06
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: A popup created with "cursorline" will ignore "firstline".
Solution: When both "cursorline" and "firstline" are present put the cursor
on "firstline". (closes vim/vim#7000) Add the "winid" argument to
getcurpos().
https://github.com/vim/vim/commit/99ca9c4868bb1669706b9e3de9a9218bd11cc459
Skip popup window related code.
Cherry-pick all of Test_getcurpos_setpos() from patch 8.2.0610.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Crash when using garbagecollect() in between rand().
Solution: Redesign the rand() and srand() implementation. (Yasuhiro
Matsumoto, closes vim/vim#5587, closes vim/vim#5588)
https://github.com/vim/vim/commit/4f645c54efe33d7a11e314676e503118761f08a7
Omit test_srand_seed.
Unmacroify SHUFFLE_XOSHIRO128STARSTAR and SPLITMIX32 while we're at it (leave
ROTL alone as it's fairly innocent).
|
| |
| |
| |
| |
| |
| |
| | |
Problem: rand() does not use the best algorithm.
Solution: use xoshiro128** instead of xorshift. (Kaito Udagawa,
closes vim/vim#5279)
https://github.com/vim/vim/commit/f8c1f9200c4b50969a8191a4fe0b0d09edb38979
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Using time() for srand() is not very random.
Solution: use /dev/urandom if available
https://github.com/vim/vim/commit/07e4a197953d12902fb97beb48830a5323a52280
Use os_open and os_close.
time_settime is N/A, so some parts of the test are disabled.
There's maybe a very, very, very, very small chance the /dev/urandom test fails,
but it shouldn't matter. :P
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Random number generator in Vim script is slow.
Solution: Add rand() and srand(). (Yasuhiro Matsumoto, closes vim/vim#1277)
https://github.com/vim/vim/commit/06b0b4bc27077013e9b4b48fd1d9b33e543ccf99
Add missing method call usage to builtin.txt.
vim_time and test_settime is N/A.
Add a modeline to test_random.vim.
Use typval_T* over listitem_T* vars so we don't need to use TV_LIST_ITEM_TV all
over the place...
Remove NULL list checks (tv_list_len covers this).
|
|\ \
| | |
| | | |
vim-patch:8.1.{0846,0878,0884,2358},8.2.{0305,0352,0687,3797}
|
| |/
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Not easy to recognize the system Vim runs on.
Solution: Add more items to the features list. (Ozaki Kiichi, closes vim/vim#3855)
https://github.com/vim/vim/commit/39536dd557e847e80572044c2be319db5886abe3
Some doc changes have already been applied. Some others are N/A.
"moon" was removed in patch 8.2.0427 so I did not add it.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
We have to be sure that the bugs fixed in the previous patches also apply to
nvim_win_call.
Checking v8.1.2124 and v8.2.4026 is especially important as these patches were
only applied to win_execute, but nvim_win_call is also affected by the same
bugs. A lot of win_execute's logic can be shared with nvim_win_call, so factor
it out into a common macro to reduce the possibility of this happening again.
|
| |
| |
| |
| |
| |
| | |
Problem: ml_get error with specific win_execute() command. (Sean Dewar)
Solution: Check cursor and Visual area are OK.
https://github.com/vim/vim/commit/e664a327014f4aa8baf8549a34a4caab2f3116a3
|
|/
|
|
|
|
|
|
|
|
|
| |
Problem: ml_get error when win_execute redraws with Visual selection.
Solution: Disable Visual area temporarily. (closes vim/vim#9479)
https://github.com/vim/vim/commit/18f4740f043b353abe47b7a00131317052457686
{switch_to/restore}_win_for_buf is N/A (marked as such in v8.0.0860; currently
only used in Vim's if_py).
Add a modeline to test_execute_func.vim.
|
|
|
|
|
|
| |
These versions of python has reached End-of-life. getting rid
of python2 support removes a lot of logic to support two
incompatible python versions in the same version.
|
| |
|
| |
|
|\
| |
| | |
feat(--headless): do not print anything when stdioopen() has been used
|
| |
| |
| |
| |
| |
| |
| | |
This commit adds an on_print callback to stdioopen's dictionary
argument which lets the caller specify a function called each time
neovim will try to output something to stdout (e.g. on "echo" or
"echoerr" in --headless mode).
|
| |
| |
| |
| |
| |
| | |
Problem: Duplicate assignment.
Solution: Remove the second assignment. (closes vim/vim#9442)
https://github.com/vim/vim/commit/4b1478093eb8b8bebc94b1f596e0afc25db4d189
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Behavioral changes:
1. Added support for lua function in keymaps in
--------------------------------------------
- nvim_set_keymap
Can set lua function as keymap rhs like following:
```lua
vim.api.nvim_{buf_}set_keymap('n', '<leader>lr', '', {callback = vim.lsp.buf.references})
```
Note: lua function can only be set from lua . If api function being
called from viml or over rpc this option isn't available.
- nvim_{buf_}get_keymap
When called from lua, lua function is returned is `callback` key .
But in other cases callback contains number of the function ref.
- :umap, nvim_del_keymap & nvim_buf_del_keymap clears lua keymaps correctly.
- :map commands for displaing rhs .
For lua keymaps rhs is displayed as <Lua function ref_no>
Note: lua keymap cannot be set through viml command / functions.
- mapargs()
When dict is false it returns string in `<Lua function ref_no>`
format (same format as :map commands).
When dict is true it returns ref_no number in `callback` key.
- mapcheck()
returns string in `<Lua function ref_no>` format (same format as :map commands).
2. Added support for keymap description
---------------------------------------
- nvim_{buf_}set_keymap: added `desc` option in opts table .
```lua
vim.api.nvim_set_keymap('n', '<leader>w', '<cmd>w<cr>', {desc='Save current file'})
```
- nvim_{buf_}get_keymap: contains `desc` in returned list.
- commands like `:nmap <leader>w` will show description in a new line below rhs.
- `maparg()` return dict contains `desc`.
|
|\ \
| | |
| | | |
refactor: remove unused macros
|
| | |
| | |
| | |
| | | |
Closes #13505
|
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: More duplicated code in f_getreginfo().
Solution: Also use getreg_get_regname(). (closes vim/vim#9398)
https://github.com/vim/vim/commit/d3f00f54bf955bd01767db3a0af25866bc112ec7
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: getreg() and getregtype() contain dead code.
Solution: Remove the needless check. (closes vim/vim#9392) Also refactor to put
common code in a shared function.
https://github.com/vim/vim/commit/51e64b2789eb7e60f7c5892a43426ab4ec1a54aa
|
|/ /
| |
| |
| |
| |
| |
| | |
xmalloc() always retuns a valid pointer.
Calling os_chdir() with the same directory as the current one doesn't do
anything other than wasting time.
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
| |
feat(eval): add reg_recorded()
This function is used the get the last recorded register.
style(Recording): rename handler to match suggestions
fix(RecordingLeave): send autocommand earlier
This makes the autocommand fire just before setting reg_recorded to
reg_recording, this way we clearly show that we are actually just before
actually quitting the recording mode.
|
|
|
|
|
| |
Possibly dialog code is messages.c could be moved here as well.
misc1.c is now empty, so delete it.
|
| |
|
|\
| |
| | |
vim-patch:7.4.1777,8.1.{1925,1995,2011,2012,2013,2166},8.2.{0532,0871,1168,1241,3576}
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Newly added features can escape the sandbox.
Solution: Add checks for restricted and secure. (Yasuhiro Matsumoto)
https://github.com/vim/vim/commit/3849992b16011e36a5cb5be4b127f843389b96fd
timer_start is missing check_secure.
The timer callback can, for example, call a function defined from outside the sandbox that does
stuff that would be disallowed from inside the sandbox. This is usually not allowed.
Cherry-pick eval.txt change from:
https://github.com/vim/vim/commit/68e6560b84f196c82e27a72669684d5506a3a837
Required for v8.1.2013.
|
| | |
|
| | |
|
|/
|
|
|
| |
Disable formatting for assert.h since there's a bug that results in a
segmentation fault in uncrustify.
|
|\
| |
| | |
vim-patch:8.2.{3468,3617,3618,3622}: some other CWD related patches
|
| |
| |
| |
| |
| |
| |
| | |
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
|
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: getcompletion() always passes zero as position to custom
completion function.
Solution: Pass the pattern length. (closes vim/vim#9173)
https://github.com/vim/vim/commit/4785fe02bba14c4e0aede0fa425ca790a1cb98d7
Co-authored-by: ii14 <ii14@users.noreply.github.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* sp_enum_after_assign = force
* sp_brace_typedef = force
* nl_do_brace = remove
* sp_do_brace_open = force
* sp_brace_close_while = force
* sp_before_semi = remove
* sp_before_semi_for = remove
* sp_before_semi_for_empty = remove
* sp_between_semi_for_empty = remove
* sp_after_semi_for_empty = remove
* sp_before_square = remove
* sp_before_squares = remove
* sp_inside_square = remove
* sp_inside_fparens = remove
* sp_inside_fparen = remove
* sp_inside_tparen = remove
* sp_after_tparen_close = remove
* sp_return_paren = force
* pos_bool = lead
* sp_pp_concat = remove
* sp_pp_stringify = remove
* fixup: disable formatting for the INIT section
|
|/
|
|
|
|
|
|
|
|
|
| |
* fix(eval): fixup for empty modifier in fnamemodify
https://github.com/neovim/neovim/commit/1dbbaf89bf5d3bcd1edac3af9938c2e2dd18f816
erroneously removed a check for empty modifier and a PVS fix.
Restore that check and fix.
Fixes #16367
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
|
|
|
| |
* refactor: reduce number of explicit char casts
|
|
|
|
| |
clean up docs for MB_PTR_ADV and MB_PTR_BACK
|
| |
|
| |
|
|
|
|
|
|
| |
Problem: Argument for message functions is inconsistent.
Solution: Make first argument to msg() "char *".
https://github.com/vim/vim/commit/32526b3c1846025f0e655f41efd4e5428da16b6c
|
|
|
|
|
|
|
|
|
| |
Problem: Giving error messages is not flexible.
Solution: Add semsg(). Change argument from "char_u *" to "char *", also
for msg() and get rid of most MSG macros. (Ozaki Kiichi, closes
vim/vim#3302) Also make emsg() accept a "char *" argument. Get rid of
an enormous number of type casts.
https://github.com/vim/vim/commit/f9e3e09fdc93be9f0d47afbc6c7df1188c2a5a0d
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* refactor: general good option changes
sp_deref = remove
sp_not = remove
sp_inv = remove
sp_inside_paren_cast = remove
mod_remove_duplicate_include = true
sp_after_semi = add
sp_after_semi_for = force
sp_sizeof_paren = remove
nl_return_expr = remove
nl_else_brace = remove
nl_else_if = remove
* refactor: mod_remove_extra_semicolon = true
* refactor: nl_max = 3
* refactor: sp_bool = force
* refactor: sp_compare = force
* refactor: sp_inside_paren = remove
* refactor: sp_paren_paren = remove
* refactor: sp_inside_sparen = remove
* refactor: sp_before_sparen = force
* refactor: sp_sign = remove
* refactor: sp_addr = remove
* refactor: sp_member = remove
* refactor: nl_struct_brace = remove
* refactor: nl_before_if_closing_paren = remove
* refactor: nl_fdef_brace = force
* refactor: sp_paren_comma = force
* refactor: mod_full_brace_do = add
|
| |
|
|
|
|
|
|
|
|
| |
Problem:
has('wsl') is decided at build-time.
Solution:
Check os_uname().
Fixes #12642, #16143
|
| |
|
|
|
|
|
|
| |
Cherry-pick check_for_nonempty_string() from patch vim-8.2.2133 and
apply it on the bases of https://github.com/neovim/neovim/pull/13489
https://github.com/vim/vim/commit/2a9d5d386bea8455b37c1accebc45683ec51d6fb
|
|\
| |
| | |
vim-patch:8.1.2368,8.1.2378,8.1.2379,8.1.2380,8.1.2387,8.1.2388,8.1.2392,8.1.2394,8.1.2395,8.1.2396
|