mirror of
https://github.com/neovim/neovim.git
synced 2025-09-28 05:58:33 +00:00
Replace ga->ga_len > 0 checks with !GA_EMPTY(ga)
Used Coccinelle to perform the changes ```diff @@ expression E; @@ <... ( - E.ga_len > 0 + !GA_EMPTY(&E) | - E->ga_len > 0 + !GA_EMPTY(E) ) ...> ``` `spatch --in-place --sp-file ga_empty.cocci <C_FILE>`
This commit is contained in:

committed by
Thiago de Arruda

parent
659cd0e99a
commit
b4efff6523
@@ -580,7 +580,7 @@ void ex_breakdel(exarg_T *eap)
|
||||
if (todel < 0)
|
||||
EMSG2(_("E161: Breakpoint not found: %s"), eap->arg);
|
||||
else {
|
||||
while (gap->ga_len > 0) {
|
||||
while (!GA_EMPTY(gap)) {
|
||||
free(DEBUGGY(gap, todel).dbg_name);
|
||||
vim_regfree(DEBUGGY(gap, todel).dbg_prog);
|
||||
--gap->ga_len;
|
||||
|
Reference in New Issue
Block a user