patch 9.0.2005: partially revert patch v9.0.1997
Problem: partially revert patch v9.0.1997
Solution: add a comment, to make clear it's not used
related: #13288
Signed-off-by: Christian Brabandt <cb@256bit.org>
diff --git a/src/move.c b/src/move.c
index a0d3a60..42878e4 100644
--- a/src/move.c
+++ b/src/move.c
@@ -1753,7 +1753,12 @@
++row;
}
if (col > width2 && width2 > 0)
+ {
row += col / width2;
+ // even so col is not used anymore,
+ // make sure it is correct, just in case
+ col = col % width2;
+ }
if (row >= curwin->w_height)
{
curwin->w_curswant = curwin->w_virtcol
@@ -1986,7 +1991,12 @@
++row;
}
if (col > width2)
+ {
row += col / width2;
+ // col may no longer be used, but make
+ // sure it is correct anyhow, just in case
+ col = col % width2;
+ }
if (row >= curwin->w_height)
{
if (curwin->w_skipcol == 0)