1
0
forked from aniani/vim

patch 8.2.4540: line number for error is off by one

Problem:    Line number for error is off by one.
Solution:   Remember the line number of the comparison. (closes #9923)
This commit is contained in:
Bram Moolenaar
2022-03-10 20:01:50 +00:00
parent 53ba6ca5b2
commit 1b1df95f1a
3 changed files with 12 additions and 0 deletions

View File

@@ -844,6 +844,13 @@ def Test_expr4_compare_none()
v9.CheckDefAndScriptFailure(['echo [] == v:none'], 'E1072: Cannot compare list with special')
v9.CheckDefAndScriptFailure(['echo 123 == v:none'], 'E1072: Cannot compare number with special')
v9.CheckDefAndScriptFailure(['echo 0z00 == v:none'], 'E1072: Cannot compare blob with special')
lines =<< trim END
echo [] == v:none
eval 0 + 0
END
v9.CheckDefAndScriptFailure(lines, 'E1072:', 1)
enddef
def Test_expr4_wrong_type()