Jan Edmund Lazo
c2ceed4994
quickfix: fix dead assignment
...
Cherry-picked from vim patch 8.1.1489.
2019-11-13 19:25:40 -05:00
Jan Edmund Lazo
8d70335b00
vim-patch:8.1.0622: adding quickfix items marks items as valid errors #11373
...
Problem: Adding quickfix items marks items as valid errors. (Daniel Hahler)
Solution: Check when items are valid. (Yegappan Lakshmanan, closes vim/vim#3683 ,
closes vim/vim#3633 )
9752c72f49
2019-11-11 21:24:25 -08:00
Jan Edmund Lazo
099c38efed
quickfix: fix pvs/v547
2019-11-09 10:11:56 -05:00
Marco Hinz
610755ff62
Merge PR #11291 from shanesmith/vim-8.1.1256-take2
2019-11-04 12:28:31 +01:00
Jan Edmund Lazo
6c5772f7da
quickfix: fix pvs/v547 error
2019-11-02 14:26:49 -04:00
Shane Smith
98d7c7db12
Minor updates and comment format fixes
...
- cursel argument for qf_list_entry() changed from int to bool
- Return type of qf_list_has_valid_entries() changed from int to bool
- Unnecessary size_t casting in qf_new_list removed
- Use Doxygen-style comment blocks for functions
2019-11-01 00:25:51 -04:00
Shane Smith
a4d48d37c1
vim-patch:8.1.1256: cannot navigate through errors relative to the cursor
...
Problem: Cannot navigate through errors relative to the cursor.
Solution: Add :cabove, :cbelow, :labove and :lbelow. (Yegappan Lakshmanan,
closes vim/vim#4316 )
3ff33114d7
2019-10-27 23:43:47 -04:00
Shane Smith
cf7c34dea1
vim-patch:8.1.1112: duplicate code in quickfix file
...
Problem: Duplicate code in quickfix file.
Solution: Move code into functions. (Yegappan Lakshmanan, closes vim/vim#4207 )
87f59b09ea
2019-10-27 23:24:54 -04:00
Shane Smith
c222f3e006
vim-patch:8.1.1098: quickfix code duplication
...
Problem: Quickfix code duplication.
Solution: Refactor the qf_init_ext() function. (Yegappan Lakshmanan,
closes vim/vim#4193 )
95946f1209
2019-10-27 23:15:28 -04:00
Shane Smith
e55eac92c6
vim-patch:8.1.1062: quickfix code is repeated
...
Problem: Quickfix code is repeated.
Solution: Define FOR_ALL_QFL_ITEMS(). Move some code to separate functions.
(Yegappan Lakshmanan, closes vim/vim#4166 )
a16123a666
2019-10-27 22:42:29 -04:00
Shane Smith
d10d7aed79
vim-patch:8.1.1030: quickfix function arguments are inconsistent
...
Problem: Quickfix function arguments are inconsistent.
Solution: Pass a list pointer instead of info and index. (Yegappan
Lakshmanan, closes vim/vim#4135 )
0398e00a1b
2019-10-27 16:25:59 -04:00
Shane Smith
7714c9e210
vim-patch:8.1.1006: repeated code in quickfix support
...
Problem: Repeated code in quickfix support.
Solution: Move code to functions. (Yegappan Lakshmanan, closes vim/vim#4091 )
4aa47b28f4
2019-10-27 16:19:17 -04:00
Shane Smith
0f93528d1f
vim-patch:8.1.0532: cannot distinguish between quickfix and location list
...
Problem: Cannot distinguish between quickfix and location list.
Solution: Add an explicit type variable. (Yegappan Lakshmanan)
2d67d307ee
2019-10-27 16:19:17 -04:00
Shane Smith
8d10241a62
vim-patch:8.1.0488: using freed memory in quickfix code
...
Problem: Using freed memory in quickfix code. (Dominique Pelle)
Solution: Add the quickfix_busy() flag to postpone deleting quickfix lists
until it is safe. (Yegappan Lakshmanan, closes #3538 )
9f84ded38b
2019-10-27 16:17:35 -04:00
Shane Smith
f0dc110f31
vim-patch:8.1.0469: too often indexing in qf_lists[]
...
Problem: Too often indexing in qf_lists[].
Solution: Use a qf_list_T pointer. (Yegappan Lakshmanan)
108e7b422b
2019-10-27 15:33:30 -04:00
Shane Smith
b041096ed4
vim-patch:8.1.0407: quickfix code mixes using the stack and a list pointer
...
Problem: Quickfix code mixes using the stack and a list pointer.
Solution: Use a list pointer in more places. (Yegappan Lakshmanan,
closes vim/vim#3443 )
fe15b7dfa6
2019-10-27 15:33:30 -04:00
Shane Smith
a123050c1a
vim-patch:8.1.0252: quickfix functions are too long
...
Problem: Quickfix functions are too long.
Solution: Refactor. (Yegappan Lakshmanan, closes vim/vim#2950 )
de3b3677f7
2019-10-27 15:33:29 -04:00
Jan Edmund Lazo
0f7a645f54
vim-patch:8.1.2154: quickfix window height wrong when there is a tabline
...
Problem: Quickfix window height wrong when there is a tabline. (Daniel
Hahler)
Solution: Take the tabline height into account. (closes vim/vim#5058 )
1142a31b8c
2019-10-27 11:35:11 -04:00
Jan Edmund Lazo
7c26be61bb
vim-patch:8.1.1245: ":copen 10" sets height in full-height window
...
Problem: ":copen 10" sets height in full-height window. (Daniel Hahler)
Solution: Don't set the height if the quickfix window is full height.
(closes vim/vim#4325 )
36d502225c
2019-10-27 11:31:10 -04:00
Jan Edmund Lazo
c3d81a4902
vim-patch:8.1.2220: :cfile does not abort like other quickfix commands
...
Problem: :cfile does not abort like other quickfix commands.
Solution: Abort when desired. Add tests for aborting. (Yegappan Lakshmanan,
closes vim/vim#5121 )
6a0cc916bd
2019-10-26 20:23:53 -04:00
Jaehwang Jerry Jung
034077ed1c
vim-patch:8.1.2173: searchit() has too many arguments
...
Problem: Searchit() has too many arguments.
Solution: Move optional arguments to a struct. Add the "wrapped" argument.
92ea26b925
2019-10-27 03:35:19 +09:00
Jan Edmund Lazo
0b771cd9aa
vim-patch:8.1.0859: handle multibyte "%v" in 'errorformat' #11285
...
Problem: "%v" in 'errorformat' does handle multi-byte characters.
Solution: Handle multi-byte characters. (Yegappan Lakshmanan, closes vim/vim#3700 )
c45eb770a5
2019-10-25 22:17:21 -07:00
Jan Edmund Lazo
8daefa348e
vim-patch:8.1.0455: checking for empty quickfix stack is not consistent
...
Problem: Checking for empty quickfix stack is not consistent.
Solution: Use qf_stack_empty(). (Yegappan Lakshmanan)
019dfe6855
2019-10-23 01:33:17 -04:00
Jan Edmund Lazo
aa8f059397
vim-patch:8.1.0438: the ex_make() function is too long
...
Problem: The ex_make() function is too long.
Solution: Split it into several functions. (Yegappan Lakshmanan)
b434ae2a1f
2019-10-23 01:33:16 -04:00
Jan Edmund Lazo
279ff23379
vim-patch:8.1.0434: copy_loclist() is too long
...
Problem: copy_loclist() is too long.
Solution: Split in multiple functions. (Yegappan Lakshmanan)
09037503ea
2019-10-23 01:33:16 -04:00
Jan Edmund Lazo
8257d49ff6
vim-patch:8.1.0410: the ex_copen() function is too long
...
Problem: The ex_copen() function is too long.
Solution: Refactor to split off two functions. (Yegappan Lakshmanan)
476c0db002
2019-10-23 01:33:16 -04:00
Jan Edmund Lazo
f3d6d8750b
vim-patch:8.1.0345: cannot get the window id associated with the location list
...
Problem: Cannot get the window id associated with the location list.
Solution: Add the "filewinid" argument to getloclist(). (Yegappan
Lakshmanan, closes vim/vim#3202 )
c9cc9c78f2
2019-10-23 01:33:16 -04:00
Jan Edmund Lazo
5e02bd071e
vim-patch:8.1.0288: quickfix code uses cmdidx too often
...
Problem: Quickfix code uses cmdidx too often.
Solution: Add is_loclist_cmd(). (Yegappan Lakshmanan)
396659592f
2019-10-23 01:33:16 -04:00
Jan Edmund Lazo
6dceaf3361
vim-patch:8.1.0014: qf_init_ext() is too long
...
Problem: qf_init_ext() is too long.
Solution: Split it into multiple functions. (Yegappan Lakshmanan,
closes vim/vim#2939 )
6053f2d29a
2019-10-23 01:33:15 -04:00
Jan Edmund Lazo
4518f230fa
vim-patch:8.1.0330: the qf_add_entries() function is too long
...
Problem: The qf_add_entries() function is too long.
Solution: Split in two parts. (Yegappan Lakshmanan)
6f6ef7c195
2019-10-02 00:52:22 -04:00
Jan Edmund Lazo
ada2ec4416
vim-patch:8.1.0315: helpgrep with language doesn't work properly
...
Problem: Helpgrep with language doesn't work properly. (Takuya Fujiwara)
Solution: Check for the language earlier. (Hirohito Higashi)
c631f2df62
2019-10-01 22:27:45 -04:00
Jan Edmund Lazo
655085204e
vim-patch:8.1.0230: directly checking 'buftype' value
...
Problem: Directly checking 'buftype' value.
Solution: Add the bt_normal() function. (Yegappan Lakshmanan)
91335e5a67
2019-10-01 22:27:45 -04:00
Jan Edmund Lazo
56c860ac4a
quickfix: fix pvs/v547 errors
2019-10-01 22:27:44 -04:00
Jan Edmund Lazo
0253f0cd92
vim-patch:8.1.0010: efm_to_regpat() is too long
...
Problem: efm_to_regpat() is too long.
Solution: Split off three functions. (Yegappan Lakshmanan, closes vim/vim#2924 )
6bff719f7e
2019-10-01 22:27:42 -04:00
Jan Edmund Lazo
6d213593ed
vim-patch:8.0.1754: ex_helpgrep() is too long #11084
...
Problem: ex_helpgrep() is too long.
Solution: Refactor the function. (Yegappan Lakshmanan, closes vim/vim#2766 )
2225ebb486
2019-09-23 22:28:04 -07:00
Jan Edmund Lazo
d9032308fb
vim-patch:8.0.1812: refactor qf_jump_to_usable_window() #11078
...
Problem: The qf_jump_to_usable_window() function is too long.
Solution: Split it in parts. (Yegappan Lakshmanan, closes vim/vim#2891 )
7a2b0e55e9
2019-09-22 18:56:31 -07:00
Jan Edmund Lazo
27fd4f31fd
vim-patch:8.1.0289: cursor moves to wrong column after quickfix jump
...
Problem: Cursor moves to wrong column after quickfix jump.
Solution: Set the curswant flag. (Andy Massimino, closes vim/vim#3331 )
2dfcef4c08
2019-09-14 12:31:47 -04:00
Jan Edmund Lazo
5f95b35c7a
vim-patch:8.1.0267: no good check if restoring quickfix list worked
...
Problem: No good check if restoring quickfix list worked.
Solution: Let qf_restore_list() return OK/FAIL. (Yegappan Lakshmanan)
90f1e2b7bc
2019-09-13 02:15:33 -04:00
Jan Edmund Lazo
47357270ae
vim-patch:8.1.0261: Coverity complains about a negative array index
...
Problem: Coverity complains about a negative array index.
Solution: When qf_id2nr() cannot find the list then don't set qf_curlist.
38efd1d17a
2019-09-13 01:41:01 -04:00
Jan Edmund Lazo
fba9c72495
vim-patch:8.1.0259: no test for fixed quickfix issue
...
Problem: No test for fixed quickfix issue.
Solution: Add a test. Clean up the code a bit. (Yegappan Lakshmanan)
3f347e4716
2019-09-13 00:47:30 -04:00
Jan Edmund Lazo
4ef9ad0514
vim-patch:8.1.0248: duplicated quickfix code
...
Problem: duplicated quickfix code.
Solution: Move the code to a function.
8d8a65e389
2019-09-13 00:35:14 -04:00
Jan Edmund Lazo
8ba492e4e2
vim-patch:8.0.1772: quickfix: mixup of FALSE and FAIL, returning -1
...
Problem: Quickfix: mixup of FALSE and FAIL, returning -1.
Solution: Use FAIL and INVALID_QFIDX. (Yegappan Lakshmanan)
29ce409bfc
2019-09-13 00:14:04 -04:00
Jan Edmund Lazo
4a6ab3494a
quickfix: fix pvs/v547 warning
2019-09-10 21:54:04 -04:00
Daniel Hahler
1dab52f878
vim-patch:8.0.1332: enhance quickfix highlighting #10259
...
Problem: Highlighting in quickfix window could be better. (Axel Bender)
Solution: Use the qfSeparator highlight item. (Yegappan Lakshmanan)
93a32e2ec4
This adds `syn_name2attr` already (from previous patch 8.0.1123,
vim/vim@1b9645de3 ).
2019-09-06 09:17:24 -07:00
Jan Edmund Lazo
9d50d033bc
vim-patch:8.0.1844: superfluous quickfix code, missing examples
...
Problem: Superfluous quickfix code, missing examples.
Solution: Remove unneeded code. Add a few examples. Add a bit more
testing. (Yegappan Lakshmanan, closes vim/vim#2916 )
78ddc06bdd
2019-09-04 02:05:25 -04:00
Jan Edmund Lazo
7876f4f218
vim-patch:8.0.1752: qf_set_properties() is to long
...
Problem: qf_set_properties() is to long.
Solution: Refactor the function. Define INVALID_QFIDX. (Yegappan
Lakshmanan, closes vim/vim#2812 )
a2aa8a2b22
2019-09-04 01:34:18 -04:00
Justin M. Keyes
d1bed81ad8
PVS/V547: Expression is always false
...
ll_get_or_alloc_list() never fails because OOM is an abort condition.
2019-09-02 04:50:22 +02:00
Marco Hinz
53b7f60805
vim-patch:8.1.0141: :cexpr no longer jumps to the first error #10901
...
Problem: :cepxr no longer jumps to the first error.
Solution: Use the quickfix list identifier. (Yegappan Lakshmanan)
Fixes https://github.com/neovim/neovim/issues/10895
2019-09-01 08:46:07 -07:00
Bartosz Miera
16727dcf1e
clang/"dead assignments" #10620
...
Also revert possibly-wrong change in f_sign_getplaced() from
652be3cb00
.
2019-07-29 00:52:24 +02:00
Ihor Antonov
cfa2759df6
PVS/V560: expression is always false/true #10623
2019-07-28 17:58:24 +02:00