diff options
author | Michael Lingelbach <m.j.lbach@gmail.com> | 2021-01-05 03:20:20 -0800 |
---|---|---|
committer | Michael Lingelbach <m.j.lbach@gmail.com> | 2021-01-31 11:57:22 -0800 |
commit | 9f2335937e7ecb59daf1bb8c4b3706ef8e3fea70 (patch) | |
tree | 563c1a4e02b66b42c22b6e49b6eadad2db9e3d1a /src/nvim/api/buffer.c | |
parent | b2713f11b48fe8029aeae07ef6a55ef182a4fbfd (diff) | |
download | rneovim-9f2335937e7ecb59daf1bb8c4b3706ef8e3fea70.tar.gz rneovim-9f2335937e7ecb59daf1bb8c4b3706ef8e3fea70.tar.bz2 rneovim-9f2335937e7ecb59daf1bb8c4b3706ef8e3fea70.zip |
fix_cursor: do not change line number when edit will not impact cursor
row
Diffstat (limited to 'src/nvim/api/buffer.c')
-rw-r--r-- | src/nvim/api/buffer.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/src/nvim/api/buffer.c b/src/nvim/api/buffer.c index 67f4f92bf6..a83b0ea859 100644 --- a/src/nvim/api/buffer.c +++ b/src/nvim/api/buffer.c @@ -1918,7 +1918,6 @@ static void fix_cursor(linenr_T lo, linenr_T hi, linenr_T extra) curwin->w_cursor.lnum += extra; check_cursor_col(); } else if (extra < 0) { - curwin->w_cursor.lnum = lo; check_cursor(); } else { check_cursor_col(); |