To: vim_dev@googlegroups.com Subject: Patch 8.2.4049 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.2.4049 Problem: Vim9: reading before the start of the line with "$" by itself. Solution: Do not subtract one when reporting the error. Files: src/vim9expr.c, src/testdir/test_vim9_expr.vim *** ../vim-8.2.4048/src/vim9expr.c 2022-01-06 21:10:24.469027861 +0000 --- src/vim9expr.c 2022-01-09 13:34:18.399977592 +0000 *************** *** 1233,1239 **** len = get_env_len(arg); if (len == 0) { ! semsg(_(e_syntax_error_at_str), start - 1); return FAIL; } --- 1233,1239 ---- len = get_env_len(arg); if (len == 0) { ! semsg(_(e_syntax_error_at_str), start); return FAIL; } *** ../vim-8.2.4048/src/testdir/test_vim9_expr.vim 2021-12-25 21:43:24.300302785 +0000 --- src/testdir/test_vim9_expr.vim 2022-01-09 13:29:21.056143691 +0000 *************** *** 2853,2858 **** --- 2853,2859 ---- CheckDefAndScriptSuccess(lines) CheckDefAndScriptFailure(["var x = $$$"], ['E1002:', 'E15:'], 1) + CheckDefAndScriptFailure(["$"], ['E1002:', 'E15:'], 1) enddef def Test_expr7_register() *** ../vim-8.2.4048/src/version.c 2022-01-09 12:57:45.118669470 +0000 --- src/version.c 2022-01-09 13:33:23.816020452 +0000 *************** *** 752,753 **** --- 752,755 ---- { /* Add new patch number below this line */ + /**/ + 4049, /**/ -- hundred-and-one symptoms of being an internet addict: 269. You wonder how you can make your dustbin produce Sesame Street's Oscar's the Garbage Monster song when you empty it. /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// \\\ \\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///