patch 9.1.0376: Vim9: Trailing commands after class/enum keywords ignored

Problem:  Vim9: Trailing commands after class/enum keywords ignored
Solution: Remove EX_TRLBAR keyword from command definition
          (Yegappan Lakshmanan)

closes: #14649

Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
diff --git a/src/vim9class.c b/src/vim9class.c
index 52c2f76..4314b52 100644
--- a/src/vim9class.c
+++ b/src/vim9class.c
@@ -136,6 +136,13 @@
 	fill_evalarg_from_eap(&evalarg, eap, FALSE);
 	(void)skip_expr_concatenate(&init_arg, &expr_start, &expr_end, &evalarg);
 
+	init_arg = skipwhite(init_arg);
+	if (*init_arg != NUL)
+	{
+	    semsg(_(e_trailing_characters_str), init_arg);
+	    return FAIL;
+	}
+
 	// No type specified for the member.  Set it to "any" and the correct
 	// type will be set when the object is instantiated.
 	if (type == NULL)