comparison src/misc2.c @ 28169:bef82285dda0 v8.2.4610

patch 8.2.4610: some conditions are always true Commit: https://github.com/vim/vim/commit/fe154990c1c57fac6d5a4b1bfb682e27adb4eb8c Author: Bram Moolenaar <Bram@vim.org> Date: Tue Mar 22 20:42:12 2022 +0000 patch 8.2.4610: some conditions are always true Problem: Some conditions are always true. Solution: Remove the useless conditions. (closes https://github.com/vim/vim/issues/9993)
author Bram Moolenaar <Bram@vim.org>
date Tue, 22 Mar 2022 21:45:04 +0100
parents 269f89efb06a
children ce202d2984a0
comparison
equal deleted inserted replaced
28168:c792d2f2af19 28169:bef82285dda0
594 win->w_cursor.coladd = oldcoladd - win->w_cursor.col; 594 win->w_cursor.coladd = oldcoladd - win->w_cursor.col;
595 595
596 // Make sure that coladd is not more than the char width. 596 // Make sure that coladd is not more than the char width.
597 // Not for the last character, coladd is then used when the cursor 597 // Not for the last character, coladd is then used when the cursor
598 // is actually after the last character. 598 // is actually after the last character.
599 if (win->w_cursor.col + 1 < len && win->w_cursor.coladd > 0) 599 if (win->w_cursor.col + 1 < len)
600 { 600 {
601 int cs, ce; 601 int cs, ce;
602 602
603 getvcol(win, &win->w_cursor, &cs, NULL, &ce); 603 getvcol(win, &win->w_cursor, &cs, NULL, &ce);
604 if (win->w_cursor.coladd > ce - cs) 604 if (win->w_cursor.coladd > ce - cs)