From 77a2eaf08bdc29f5ae6f4dc263b2a97b6cb749e8 Mon Sep 17 00:00:00 2001 From: KunMing Xie Date: Wed, 30 May 2018 15:11:52 +0800 Subject: vim-patch:8.0.0515: ml_get errors in silent Ex mode (#8452) Problem: ml_get errors in silent Ex mode. (Dominique Pelle) Solution: Clear valid flags when setting the cursor. Set the topline when not in full screen mode. https://github.com/vim/vim/commit/d5d37537d1fa46fd468bd378af2006dd09840f38 --- src/nvim/testdir/test_startup.vim | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'src/nvim/testdir') diff --git a/src/nvim/testdir/test_startup.vim b/src/nvim/testdir/test_startup.vim index 11e26d03aa..495c561991 100644 --- a/src/nvim/testdir/test_startup.vim +++ b/src/nvim/testdir/test_startup.vim @@ -240,3 +240,14 @@ func Test_progpath() " Only expect "vim" to appear in v:progname. call assert_match('vim\c', v:progname) endfunc + +func Test_silent_ex_mode() + if !has('unix') || has('gui_running') + " can't get output of Vim. + return + endif + + " This caused an ml_get error. + let out = system(GetVimCommand() . '-u NONE -es -c''set verbose=1|h|exe "%norm\\"'' -c cq') + call assert_notmatch('E315:', out) +endfunc -- cgit