diff options
Diffstat (limited to 'src/testdir/test_expr.vim')
-rw-r--r-- | src/testdir/test_expr.vim | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/testdir/test_expr.vim b/src/testdir/test_expr.vim index bd9cacafa2..1281ae72f8 100644 --- a/src/testdir/test_expr.vim +++ b/src/testdir/test_expr.vim @@ -530,3 +530,12 @@ func Test_broken_number() call assert_equal(2, str2nr('2a')) call assert_fails('inoremap <Char-0b1z> b', 'E474:') endfunc + +func Test_eval_after_if() + let s:val = '' + func SetVal(x) + let s:val ..= a:x + endfunc + if 0 | eval SetVal('a') | endif | call SetVal('b') + call assert_equal('b', s:val) +endfunc |