mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
PVS/V1037: redundant switch-case branches #10519
Suppress the warning, the branches are semantically different.
This commit is contained in:
parent
4fc91fe365
commit
452ec4ed31
@ -1108,9 +1108,8 @@ static int current_tab_nr(tabpage_T *tab)
|
||||
#define CURRENT_TAB_NR current_tab_nr(curtab)
|
||||
#define LAST_TAB_NR current_tab_nr(NULL)
|
||||
|
||||
/*
|
||||
* Figure out the address type for ":wincmd".
|
||||
*/
|
||||
|
||||
/// Figure out the address type for ":wincmd".
|
||||
static void get_wincmd_addr_type(char_u *arg, exarg_T *eap)
|
||||
{
|
||||
switch (*arg) {
|
||||
@ -1156,13 +1155,13 @@ static void get_wincmd_addr_type(char_u *arg, exarg_T *eap)
|
||||
case Ctrl_I:
|
||||
case 'd':
|
||||
case Ctrl_D:
|
||||
/* window size or any count */
|
||||
eap->addr_type = ADDR_LINES;
|
||||
// window size or any count
|
||||
eap->addr_type = ADDR_LINES; // -V1037
|
||||
break;
|
||||
|
||||
case Ctrl_HAT:
|
||||
case '^':
|
||||
/* buffer number */
|
||||
// buffer number
|
||||
eap->addr_type = ADDR_BUFFERS;
|
||||
break;
|
||||
|
||||
@ -1177,7 +1176,7 @@ static void get_wincmd_addr_type(char_u *arg, exarg_T *eap)
|
||||
case 'W':
|
||||
case 'x':
|
||||
case Ctrl_X:
|
||||
/* window number */
|
||||
// window number
|
||||
eap->addr_type = ADDR_WINDOWS;
|
||||
break;
|
||||
|
||||
@ -1192,7 +1191,7 @@ static void get_wincmd_addr_type(char_u *arg, exarg_T *eap)
|
||||
case Ctrl_P:
|
||||
case '=':
|
||||
case CAR:
|
||||
/* no count */
|
||||
// no count
|
||||
eap->addr_type = 0;
|
||||
break;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user