Problem: Translation cleanup script does not remove empty lines at end.
Solution: Remove empty lines at the end. (Ken Takata, closesvim/vim#9794)
0257599036
Problem: Wrong type for "isunnamed" returned by getreginfo().
Solution: Use VAR_BOOL instead of VAR_SPECIAL. (closesvim/vim#11598)
82946e1439
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Problem: Various pieces of code not covered by tests.
Solution: Add a few more tests. (Yegappan Lakshmanan, closesvim/vim#8255)
34fcb69724
Nvim does not have test_unknown().
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Problem: Max() and min() can give many error messages.
Solution: Bail out at the first error. (closesvim/vim#1039, closesvim/vim#7778)
ab65fc77c5
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Problem: Match highlighting of tab too short.
Solution: Do not stop match highlighting if on a Tab. (Christian Brabandt,
closesvim/vim#9507, closesvim/vim#9500)
0bbca540f7
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Problem: Match highlight disappears when doing incsearch for ":s/pat".
Solution: Only use line limit for incsearch highlighting. (closesvim/vim#9425)
94fb8274ca
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Problem: Match highlighting continues over breakindent.
Solution: Stop before the end column. (closesvim/vim#9242)
0c359af5c0
Cherry-pick Test_matchdelete_redraw() from patch 8.2.1077.
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Problem: Coverity warns for not using return value of dict_add().
Solution: When dict_add() fails then don't call hash_remove().
bc222152d8
N/A patches for version.c:
vim-patch:9.0.0927: Coverity warns for using a NULL pointer
Problem: Coverity warns for using a NULL pointer.
Solution: Check for memory allocaion failure.
96cbbe29de
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Problem: Two conditions are always false.
Solution: Remove the conditions. Update return value types to make clear
what could be returned. (closesvim/vim#11593)
df3c0eb41e
Problem: The WinScrolled autocommand event is not enough.
Solution: Add WinResized and provide information about what changed.
(closesvim/vim#11576)
35fc61cb5b
Omit "func_name" comment in tv_dict_extend(): Vim9 script only.
Skip layout locking and E1312.
Skip list_alloc_with_items() and list_set_item().
Since this overrides remaining changes in patch 9.0.0913, that patch can
now be marked as fully ported:
vim-patch:9.0.0913: only change in current window triggers the WinScrolled event
N/A patches for version.c:
vim-patch:9.0.0919: build failure with tiny features
Problem: Build failure with tiny features.
Solution: Adjust #ifdef's.
9c5b7cb4cf
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Extend the capabilities of is_os to detect more platforms such as
freebsd and openbsd. Also remove `iswin()` helper function as it can be
replaced by `is_os("win")`.
* fix(PVS/V009): start file with special comment
* fix(PVS/V501): identical sub-expressions for comparison
* fix(PVS/V560): part of conditional expression is always true/false
* fix(PVS/V593): review expression of type A = B < C
* fix(PVS/V614): potentially uninitialized variable used
Problem: getbufline() is inefficient for getting a single line.
Solution: Add getbufoneline().
ce30ccc06a
Cherry-pick part of usr_41.txt from patch 8.1.1628.
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Problem: set/getbufline test fails without the job feature.
Solution: Check whether the job feature is supported. (Dominique Pellé,
closesvim/vim#7790)
00385114db
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Problem: setline() gives an error for some types.
Solution: Allow any type, convert each item to a string.
3445320839
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Some functions didn't include the `nil` case in the return type
annotation. This corrects those and also adds a Diagnostic class
definition for the diagnostic.get return type
This introduces a `suffix` option to the `virt_text` config in
`vim.diagnostic.config()`. The suffix can either be a string which is appended
to the diagnostic message or a function returning such. The function receives a
`diagnostic` argument, which is the diagnostic table of the last diagnostic (the
one whose message is rendered as virt text).
Closes#18687
This introduces a `suffix` option to `vim.diagnostic.open_float()` (and
consequently `vim.diagnostic.config()`) that appends some text to each
diagnostic in the float.
It accepts the same types as `prefix`. For multiline diagnostics, the suffix is
only appended to the last line. By default, the suffix will render the
diagnostic error code, if any.
Problem: WinScrolled may trigger immediately when defined.
Solution: Initialize the fields in all windows. (closesvim/vim#11582)
2996773276
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Problem: Only a change in the current window triggers the WinScrolled
event.
Solution: Trigger WinScrolled if any window scrolled or changed size.
(issue vim/vim#11576)
0a60f79fd0
Skip locking of window layout and E1312.
Copy the latest version of all WinScrolled tests from Vim.
Note: patch 9.0.0915 is needed for the Lua tests to pass.
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Language servers can take some time to respond to the
`textDocument/hover` and `textDocument/signatureHelp` messages. During
that time, the user could have already moved to another buffer. The
popup was always shown in the current buffer, which could be a different
one than the buffer for which the request was sent.
This was particularly annoying when moving to a buffer with a `BufLeave`
autocmd, as that autocmd was triggered when the hover popup was shown
for the original buffer.
Ignoring the response from these 2 messages if they are for a buffer
that is not the current one leads to less noise. The popup will only be
shown for the buffer for which it was requested.
A more robust solution could involve cancelling the hover/signatureHelp
request if the buffer changes so the language server can free its
resources. It could be implemented in the future.