Mercurial > vim
comparison src/vim9compile.c @ 21172:96ae8622cfb6 v8.2.1137
patch 8.2.1137: Vim9: modifiers not cleared after compiling function
Commit: https://github.com/vim/vim/commit/47e7d70b58e8bfc1daaf6d35569ef2dbd0339ddc
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Jul 5 18:18:42 2020 +0200
patch 8.2.1137: Vim9: modifiers not cleared after compiling function
Problem: Vim9: modifiers not cleared after compiling function.
Solution: Clear command modifiers. (closes https://github.com/vim/vim/issues/6396)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sun, 05 Jul 2020 18:30:07 +0200 |
parents | 1a393685e7ce |
children | d73b6ba20053 |
comparison
equal
deleted
inserted
replaced
21171:0472770ff04e | 21172:96ae8622cfb6 |
---|---|
6807 for (;;) | 6807 for (;;) |
6808 { | 6808 { |
6809 exarg_T ea; | 6809 exarg_T ea; |
6810 int starts_with_colon = FALSE; | 6810 int starts_with_colon = FALSE; |
6811 char_u *cmd; | 6811 char_u *cmd; |
6812 int save_msg_scroll = msg_scroll; | |
6812 | 6813 |
6813 // Bail out on the first error to avoid a flood of errors and report | 6814 // Bail out on the first error to avoid a flood of errors and report |
6814 // the right line number when inside try/catch. | 6815 // the right line number when inside try/catch. |
6815 if (emsg_before != called_emsg) | 6816 if (emsg_before != called_emsg) |
6816 goto erret; | 6817 goto erret; |
6895 goto erret; | 6896 goto erret; |
6896 // empty line or comment | 6897 // empty line or comment |
6897 line = (char_u *)""; | 6898 line = (char_u *)""; |
6898 continue; | 6899 continue; |
6899 } | 6900 } |
6901 // TODO: use modifiers in the command | |
6902 undo_cmdmod(&ea, save_msg_scroll); | |
6900 | 6903 |
6901 // Skip ":call" to get to the function name. | 6904 // Skip ":call" to get to the function name. |
6902 if (checkforcmd(&ea.cmd, "call", 3)) | 6905 if (checkforcmd(&ea.cmd, "call", 3)) |
6903 ea.cmd = skipwhite(ea.cmd); | 6906 ea.cmd = skipwhite(ea.cmd); |
6904 | 6907 |