From: Wolfgang Bumiller <wry.git@bumiller.com>
Date: Fri, 26 Apr 2013 08:31:38 +0000 (+0200)
Subject: an = before an { is also always required when the declared variable is not a function... 
X-Git-Tag: v0.3.0~151^2~66
X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=b3e9ef3ad9f8f9aee8c3472efd2c4485dc684718;p=xonotic%2Fgmqcc.git

an = before an { is also always required when the declared variable is not a function; adding because of planned array initializers
---

diff --git a/parser.c b/parser.c
index 7fba786..506f8d2 100644
--- a/parser.c
+++ b/parser.c
@@ -5623,7 +5623,7 @@ skipvar:
             }
         }
 
-        if (parser->tok != '{') {
+        if (parser->tok != '{' || var->expression.vtype != TYPE_FUNCTION) {
             if (parser->tok != '=') {
                 parseerror(parser, "missing semicolon or initializer, got: `%s`", parser_tokval(parser));
                 break;