patch 8.2.2628: Vim9: #{ can still be used at the script level
Problem: Vim9: #{ can still be used at the script level.
Solution: Give an error for #{ like in a :def function.
diff --git a/src/ex_docmd.c b/src/ex_docmd.c
index 477d140..67bcc73 100644
--- a/src/ex_docmd.c
+++ b/src/ex_docmd.c
@@ -5234,7 +5234,8 @@
return TRUE;
#ifdef FEAT_EVAL
if (in_vim9script())
- return c == '#' && (cmd == cmd_start || VIM_ISWHITE(cmd[-1]));
+ return c == '#' && cmd[1] != '{'
+ && (cmd == cmd_start || VIM_ISWHITE(cmd[-1]));
#endif
return c == '"';
}