refactor: cast to int earlier when using 'so' and 'siso' (#24756)

This commit is contained in:
zeertzjq
2023-08-17 20:35:51 +08:00
committed by GitHub
parent 4292575dfc
commit 5a564bf242
6 changed files with 23 additions and 25 deletions

View File

@@ -6516,7 +6516,7 @@ static void win_fix_cursor(int normal)
}
// Determine valid cursor range.
linenr_T so = MIN(wp->w_height_inner / 2, get_scrolloff_value(wp));
int so = MIN(wp->w_height_inner / 2, get_scrolloff_value(wp));
linenr_T lnum = wp->w_cursor.lnum;
wp->w_cursor.lnum = wp->w_topline;