Mercurial > vim
view src/testdir/test_scroll_opt.vim @ 25897:f2fb5d30cd16 v8.2.3482
patch 8.2.3482: reading beyond end of line ending in quote and backslash
Commit: https://github.com/vim/vim/commit/78e0fa4cf4fcd563c0bc8c87afa54d4f5dc22020
Author: Bram Moolenaar <Bram@vim.org>
Date: Tue Oct 5 21:58:53 2021 +0100
patch 8.2.3482: reading beyond end of line ending in quote and backslash
Problem: Reading beyond end of line ending in quote and backslash.
Solution: Check for non-NUL after backslash. (closes https://github.com/vim/vim/issues/8964)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Tue, 05 Oct 2021 23:00:05 +0200 |
parents | 08940efa6b4e |
children | 6c6ac189a05f |
line wrap: on
line source
" Test for reset 'scroll' func Test_reset_scroll() let scr = &l:scroll setlocal scroll=1 setlocal scroll& call assert_equal(scr, &l:scroll) setlocal scroll=1 setlocal scroll=0 call assert_equal(scr, &l:scroll) try execute 'setlocal scroll=' . (winheight(0) + 1) " not reached call assert_false(1) catch call assert_exception('E49:') endtry split let scr = &l:scroll setlocal scroll=1 setlocal scroll& call assert_equal(scr, &l:scroll) setlocal scroll=1 setlocal scroll=0 call assert_equal(scr, &l:scroll) quit! endfunc " vim: shiftwidth=2 sts=2 expandtab