mirror of
https://github.com/vim/vim.git
synced 2025-09-25 03:54:15 -04:00
patch 9.1.0314: Vim9: Can define a class in a function
Problem: Vim9: Can define a class in a function (Doug Kearns) Solution: Give an error for a class defined in a function, slightly reword some public error messages (Yegappan Lakshmanan) fixes: #13184 fixes: #13326 closes: #14537 Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com> Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
committed by
Christian Brabandt
parent
122d068585
commit
c51578fed8
@@ -4028,10 +4028,13 @@ compile_def_function(
|
||||
line = (char_u *)"";
|
||||
break;
|
||||
|
||||
case CMD_class:
|
||||
emsg(_(e_class_can_only_be_used_in_script));
|
||||
goto erret;
|
||||
|
||||
case CMD_type:
|
||||
emsg(_(e_type_can_only_be_used_in_script));
|
||||
goto erret;
|
||||
break;
|
||||
|
||||
case CMD_global:
|
||||
if (check_global_and_subst(ea.cmd, p) == FAIL)
|
||||
|
Reference in New Issue
Block a user