Problem: No error for using "#{ comment" in a compiled function.
Solution: Make error checking for "#{" consistent. (closes #10855)
delete('Xdir', 'rf')
enddef
+def Test_comment_error()
+ v9.CheckDefFailure(['#{ comment'], 'E1170:')
+enddef
+
def Test_compile_error_in_called_function()
var lines =<< trim END
vim9script
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 174,
/**/
173,
/**/
if (*ea.cmd == '#')
{
- // "#" starts a comment
+ // "#" starts a comment, but "#{" is an error
+ if (vim9_bad_comment(ea.cmd))
+ goto erret;
line = (char_u *)"";
continue;
}