diff options
Diffstat (limited to 'src/nvim/popupmnu.c')
-rw-r--r-- | src/nvim/popupmnu.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/nvim/popupmnu.c b/src/nvim/popupmnu.c index d7726409b5..e354a589a5 100644 --- a/src/nvim/popupmnu.c +++ b/src/nvim/popupmnu.c @@ -289,8 +289,7 @@ void pum_display(pumitem_T *array, int size, int selected, bool array_changed, i if (pum_rl) { pum_width = pum_col - pum_scrollbar + 1; } else { - assert(Columns - pum_col - pum_scrollbar >= INT_MIN - && Columns - pum_col - pum_scrollbar <= INT_MAX); + assert(Columns - pum_col - pum_scrollbar >= 0); pum_width = Columns - pum_col - pum_scrollbar; } @@ -356,7 +355,6 @@ void pum_display(pumitem_T *array, int size, int selected, bool array_changed, i } else { pum_col = 0; } - assert(Columns - 1 >= INT_MIN); pum_width = Columns - 1; } else { if (max_width > p_pw) { @@ -367,8 +365,7 @@ void pum_display(pumitem_T *array, int size, int selected, bool array_changed, i if (pum_rl) { pum_col = max_width - 1; } else { - assert(Columns - max_width >= INT_MIN - && Columns - max_width <= INT_MAX); + assert(Columns - max_width >= 0); pum_col = Columns - max_width; } pum_width = max_width - pum_scrollbar; |