aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/ex_getln.c
Commit message (Collapse)AuthorAge
...
* fix(ex_getln): initialize pointer with NULLAndreas Schneider2023-04-21
| | | | | | | | In function ‘cmdpreview_open_win’, inlined from ‘cmdpreview_may_show’ at gsrc/nvim/ex_getln.c:2487:28: gsrc/nvim/ex_getln.c:2251:16: warning: ‘cmdpreview_buf’ may be used uninitialized [-Wmaybe-uninitialized] 2251 | int result = do_buffer(DOBUF_GOTO, DOBUF_FIRST, FORWARD, cmdpreview_buf->handle, 0); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
* vim-patch:9.0.1460: insufficient testing for getcmdcompltype() (#23159)zeertzjq2023-04-17
| | | | | | Problem: Insufficient testing for getcmdcompltype(). Solution: Add a few more test cases. (closes vim/vim#12268) https://github.com/vim/vim/commit/961b2e54bdbe1c06e4bf8ccf7a7e3deb129b45de
* vim-patch:9.0.1444: crash when passing NULL to setcmdline() (#23048)zeertzjq2023-04-12
| | | | | | | Problem: Crash when passing NULL to setcmdline(). (Andreas Louv) Solution: Use tv_get_string() instead of using v_string directly. (closes vim/vim#12231, closes vim/vim#12227) https://github.com/vim/vim/commit/ac6cd31afcbdd08bfa92ca33f7d4ce5773ba4353
* refactor: remove redundant castsii142023-04-07
|
* refactor: remove redundant const char * castsii142023-04-07
|
* refactor: make error message definitions constii142023-04-05
| | | | message.c functions now take const char * as a format. Error message definitions can be made const.
* refactor: remove char_u (#22829)dundargoc2023-04-02
| | | Closes https://github.com/neovim/neovim/issues/459
* feat(api): add filetype option nvim_get_option_valueLewis Russell2023-03-20
| | | | | - Also adjust the expr-mapping behaviour so normal commands and text changes are allowed in internal dummy buffers.
* refactor(screen): screen.c delenda estbfredl2023-03-14
| | | | | | | | | | | | | drawscreen.c vs screen.c makes absolutely no sense. The screen exists only to draw upon it, therefore helper functions are distributed randomly between screen.c and the file that does the redrawing. In addition screen.c does a lot of drawing on the screen. It made more sense for vim/vim as our grid.c is their screen.c Not sure if we want to dump all the code for option chars into optionstr.c, so keep these in a optionchar.c for now.
* perf(statusline): UI elements are always redrawn on K_EVENTLuuk van Baal2023-03-08
| | | | | Problem: 'statusline'-format UI elements are redrawn on each K_EVENT. Solution: Only redraw UI elements when something relevant has changed.
* vim-patch:9.0.1380: CTRL-X on 2**64 subtracts two (#22530)zeertzjq2023-03-05
| | | | | | | | Problem: CTRL-X on 2**64 subtracts two. (James McCoy) Solution: Correct computation for large number. (closes vim/vim#12103) https://github.com/vim/vim/commit/5fb78c3fa5c996c08a65431d698bd2c251eef5c7 Co-authored-by: Bram Moolenaar <Bram@vim.org>
* Merge pull request #22429 from bfredl/hkmapbfredl2023-02-28
|\ | | | | feat(edit)!: remove old c implementation of hebrew keymap
| * feat(edit)!: remove old c implementation of hebrew keymapbfredl2023-02-28
| | | | | | | | | | | | | | This feature has long been obsolete. The 'keymap' option can be used to support language keymaps, including hebrew and hebrewp (phonetic mapping). There is no need to keep the old c code with hardcoded keymaps for some languages.
* | refactor(getchar.c): change most char_u to uint8_t (#22444)zeertzjq2023-02-28
| |
* | fix: address -Wmaybe-uninitialized warnings (#22436)Lewis Russell2023-02-27
|/
* vim-patch:9.0.1299: change for triggering incsearch not sufficiently testedzeertzjq2023-02-11
| | | | | | | Problem: Change for triggering incsearch not sufficiently tested. Solution: Add a test case. Simplify the code. (closes vim/vim#11971) https://github.com/vim/vim/commit/412e0e4ed903682f352d8ea58ded480930cc664f
* vim-patch:9.0.1298: inserting register on the cmdline does not trigger incsearchzeertzjq2023-02-11
| | | | | | | | | | | Problem: Inserting a register on the command line does not trigger incsearch or update hlsearch. Solution: Have cmdline_insert_reg() return CMDLINE_CHANGED when appropriate and handle it correctly. (Ken Takata, closes vim/vim#11960) https://github.com/vim/vim/commit/c4b7dec38292fe1cfad7aa5f244031fc6f7c7a09 Co-authored-by: K.Takata <kentkt@csc.jp>
* refactor: replace char_u with char (#21901)dundargoc2023-02-11
| | | | | refactor: replace char_u with char Work on https://github.com/neovim/neovim/issues/459
* refactor: reduce scope of locals as per the style guide (#22206)dundargoc2023-02-11
|
* vim-patch:9.0.1290: CTRL-N and -P on cmdline don't trigger CmdlineChanged ↵zeertzjq2023-02-07
| | | | | | | | | | | (#22151) Problem: CTRL-N and -P on cmdline don't trigger CmdlineChanged. Solution: Jump to cmdline_changed instead of cmdline_not_changed. (closes vim/vim#11956) https://github.com/vim/vim/commit/af9e28a5b8f888b79459393ddb26fffe613c3f3c Cherry-pick Test_Cmdline() change from patch 9.0.1039.
* refactor(optionstr.c): break up did_set_string_option 7Lewis Russell2023-01-25
|
* revert: "refactor(win_close): remove "force", don't pass on "free_buf" ↵zeertzjq2023-01-24
| | | | | | | | (#21921)" (#21979) This reverts commit 0371d0f7afa5e01dd2ac8bbd3abcf0f7454872b3. > 'bufhidden' option exists. I don't think we should assume autoclosing windows are fine just because 'hidden' is set.
* refactor(win_close): remove "force", don't pass on "free_buf" (#21921)zeertzjq2023-01-23
| | | | | | | | | | | | | Problem: The "force" flag of win_close() complicates the code and adds edge cases where it is not clear what the correct behavior should be. The "free_buf" flag of win_close() is passed on to float windows when closing the last window of a tabpage, which doesn't make much sense. Solution: Remove the "force" flag and always close float windows as if :close! is used when closing the last window of a tabpage, and set the "free_buf" flag for a float window based on whether its buffer can be freed. As 'hidden' is on by default, this change shouldn't affect many people.
* refactor: replace char_u with char 24 (#21823)dundargoc2023-01-18
| | | | | refactor: replace char_u with char Work on https://github.com/neovim/neovim/issues/459
* refactor: replace char_u with char 23 (#21798)dundargoc2023-01-18
| | | Work on https://github.com/neovim/neovim/issues/459
* refactor: replace char_u with char 22 (#21786)dundargoc2023-01-17
| | | Work on https://github.com/neovim/neovim/issues/459
* refactor: remove E5500, adjust testszeertzjq2023-01-16
| | | | | | Now with try_end() including more exception info, E5500 looks like redundant information. Adjust tests for more exception information.
* vim-patch:8.2.4585: cannot use keypad page-up/down for completion menuzeertzjq2023-01-15
| | | | | | | | | Problem: Cannot use keypad page-up/down for completion menu. Solution: Recognize the keypad keys. (Yegappan Lakshmanan, closes vim/vim#9963) https://github.com/vim/vim/commit/155b0882088ff115dcfb6ce466fe7c8cc2bef349 Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
* vim-patch:8.2.4579: cannot use page-up and page-down in the cmdline popup menuzeertzjq2023-01-15
| | | | | | | | | | | Problem: Cannot use page-up and page-down in the command line completion popup menu. Solution: Check for to page-up and page-down keys. (Yegappan Lakshmanan, closes vim/vim#9960) https://github.com/vim/vim/commit/5cffa8df7e3c28681b9e5deef6df395784359b6b Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
* vim-patch:partial:8.2.4339: CTRL-A does not work properly with the cmdline ↵zeertzjq2023-01-14
| | | | | | | | | | | | | | popup menu (#21791) Problem: CTRL-A does not work properly with the cmdline popup menu. Solution: Fix issues with CTRL-A. Add more tests for the cmdline popup menu. Remove TermWait() before VeriryScreenDump(). Refactor the cmdline popup code. (Yegappan Lakshmanan, closes vim/vim#9735) https://github.com/vim/vim/commit/560dff49c0095111fc96b4b8dd7f4d269aba9473 Only port cmdexpand.c and test_cmdline.vim changes. Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
* refactor: replace char_u with char 21 (#21779)dundargoc2023-01-14
| | | | | refactor: replace char_u with char Work on https://github.com/neovim/neovim/issues/459
* refactor: replace char_u with char 20 (#21714)dundargoc2023-01-13
| | | | | refactor: replace char_u with char Work on https://github.com/neovim/neovim/issues/459
* vim-patch:partial:9.0.1166: code is indented more than necessary (#21716)zeertzjq2023-01-10
| | | | | | | | | | | | | | | | | | | | | | Problem: Code is indented more than necessary. Solution: Use an early return where it makes sense. (Yegappan Lakshmanan, closes vim/vim#11792) https://github.com/vim/vim/commit/1cfb14aa972ccf3235ac67f07b7db1175b7c5384 Partial port as some highlight.c changes depend on previous patches. Cherry-pick fname_match() change from patch 8.2.4959. Omit internal_func_check_arg_types(): only used for Vim9 script. N/A patches for version.c: vim-patch:9.0.1167: EditorConfig files do not have their own filetype Problem: EditorConfig files do not have their own filetype. Solution: Add the "editorconfig" filetype. (Gregory Anders, closes vim/vim#11779) https://github.com/vim/vim/commit/d41262ed06564cef98a3800e2928e6e0db91abbf Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
* refactor: replace char_u with char 18 (#21237)dundargoc2023-01-09
| | | | | refactor: replace char_u with char Work on https://github.com/neovim/neovim/issues/459
* refactor: replace char_u with chardundargoc2023-01-09
| | | | Work on https://github.com/neovim/neovim/issues/459
* Merge #21580 cmdline issues with cmdheight=0Justin M. Keyes2023-01-03
|\
| * fix: issues with command line if ui elements are externalizedLuuk van Baal2022-12-31
| | | | | | | | | | Resolve https://github.com/neovim/neovim/issues/20888 and handle side effects for setting 'cmdheight' to zero.
* | vim-patch:9.0.1115: code is indented more than needed (#21598)zeertzjq2022-12-31
|/ | | | | | | | | Problem: Code is indented more than needed. Solution: Use an early return to reduce indenting. (Yegappan Lakshmanan, closes vim/vim#11758) https://github.com/vim/vim/commit/ed0c1d5d4b30d03b26ff08841f6da2ddf44025a7 Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
* refactor: replace char_u with char 16 - remove STRNCMP (#21208)dundargoc2022-12-21
| | | | | refactor: replace char_u with char Work on https://github.com/neovim/neovim/issues/459
* docs: fix typos (#21328)dundargoc2022-12-12
|
* vim-patch:8.2.2870: CmdlineChange event triggered twice for CTRL-R (#21361)zeertzjq2022-12-11
| | | | | | | | | | | Problem: CmdlineChange event triggered twice for CTRL-R. Solution: Return CMDLINE_NOT_CHANGED from cmdline_insert_reg(). (closes vim/vim#8219) https://github.com/vim/vim/commit/796139ae3ac89e27ee96dce3c7fdb87d8c839f53 Cherry-pick Test_cmdline_map_cmdlineChanged() from patch 8.2.2851. Co-authored-by: Bram Moolenaar <Bram@vim.org>
* vim-patch:9.0.1038: function name does not match what it is used for (#21359)zeertzjq2022-12-09
| | | | | | Problem: Function name does not match what it is used for. Solution: Include the modifier in the name. (closes vim/vim#11679) https://github.com/vim/vim/commit/ffa4e9b43a3d6d7f412f54637a4b1076ed2bc2f4
* vim-patch:8.2.1634: loop to handle keys for the command line is too long ↵zeertzjq2022-12-08
| | | | | | | | | (#21340) Problem: Loop to handle keys for the command line is too long. Solution: Move a few more parts to separate functions. (Yegappan Lakshmanan, closes vim/vim#6895) https://github.com/vim/vim/commit/9c929713b7588f2e44a1533809d2ba0bbd2631be
* fix(events): save v:event for cmdline autocommands separately (#21316)zeertzjq2022-12-07
|
* vim-patch:8.2.1622: loop to handle keys for the command line is too long ↵zeertzjq2022-12-06
| | | | | | | | | | (#21307) Problem: Loop to handle keys for the command line is too long. Solution: Move code to functions. (Yegappan Lakshmanan, closes vim/vim#6880) https://github.com/vim/vim/commit/2f3cd2e4ec5617e3697ec4f4c6e1c9449061ad30 Use the command line state as only argument instead.
* vim-patch:8.2.2295: incsearch does not detect empty pattern properlyzeertzjq2022-12-04
| | | | | | | | Problem: Incsearch does not detect empty pattern properly. Solution: Return magic state when skipping over a pattern. (Christian Brabandt, closes vim/vim#7612, closes vim/vim#6420) https://github.com/vim/vim/commit/d93a7fc1a98a58f8101ee780d4735079ad99ae35
* vim-patch:8.2.2182: Vim9: value of 'magic' is still relevantzeertzjq2022-12-04
| | | | | | | | | | | Problem: Vim9: value of 'magic' is still relevant. Solution: Always behave like 'magic' is on in Vim9 script (closes vim/vim#7509) https://github.com/vim/vim/commit/f4e2099e39ed4d71aed0f9a9579455aed5ec6cc2 EX_NONWHITE_OK is N/A: only applies to Vim9 script. Co-authored-by: Bram Moolenaar <Bram@vim.org>
* refactor: replace char_u with chardundargoc2022-11-28
| | | | Work on https://github.com/neovim/neovim/issues/459
* refactor: replace char_u with charDundar Göc2022-11-19
| | | | Work on https://github.com/neovim/neovim/issues/459
* vim-patch:8.2.5148: invalid memory access when using expression on command ↵zeertzjq2022-11-19
| | | | | | | | | | | | | | | | | | | line (#21113) Problem: Invalid memory access when using an expression on the command line. Solution: Make sure the position does not go negative. https://github.com/vim/vim/commit/6046aded8da002b08d380db29de2ba0268b6616e N/A patches for version.c: vim-patch:8.2.5149: cannot build without the +eval feature Problem: Cannot build without the +eval feature. (Tony Mechelynck) Solution: Add #ifdefs. https://github.com/vim/vim/commit/6689df024bce4309ec5884e445738fe07ee4ffcc Co-authored-by: Bram Moolenaar <Bram@vim.org>