]> git.rm.cloudns.org Git - xonotic/gmqcc.git/commitdiff
Merge branch 'cooking' into diagnostics
authorDale Weiler <killfieldengine@gmail.com>
Thu, 30 May 2013 18:22:37 +0000 (18:22 +0000)
committerDale Weiler <killfieldengine@gmail.com>
Thu, 30 May 2013 18:22:37 +0000 (18:22 +0000)
1  2 
intrin.h
lexer.c
lexer.h
main.c
parser.c

diff --cc intrin.h
Simple merge
diff --cc lexer.c
Simple merge
diff --cc lexer.h
Simple merge
diff --cc main.c
index 158d8180d47c27d47f25c850ef7c1992a2fb9945,840a6a730fe83065b663ef92875cdb1948ba8fc9..10db6d3fa1e5f46d2d396ad4916fcf51288b9424
--- 1/main.c
--- 2/main.c
+++ b/main.c
@@@ -780,14 -778,11 +778,15 @@@ srcdone
              }
          }
      }
 -
 +{
 +    #define FOO "\xD\xE\xA\xD\xB\xE\xE\xF\xD\xE\xA\xD\xB\xE\xE\xF"
 +    char *foo = util_strdup(FOO FOO FOO FOO "hello world!");
 +    (void)foo;
 +}
  cleanup:
      util_debug("COM", "cleaning ...\n");
-     ftepp_finish();
+     if (ftepp)
+         ftepp_finish(ftepp);
      con_close();
      vec_free(items);
      vec_free(ppems);
diff --cc parser.c
index 3c63d91a03891e04d211665e8f5ecc4749d0b3f0,d9be036927c38ab3608613db3c7d2bc3b18961e6..7918f0f0e2ee3625919205286381cfb3fdf4cc7f
+++ b/parser.c
@@@ -5764,13 -5685,9 +5863,13 @@@ 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));
 +                const char *obtain = parser_tokval(parser);
 +                if (!strcmp(obtain, "}"))
 +                    parseerror(parser, "missing semicolon");
 +                else
 +                    parseerror(parser, "missing initializer");
                  break;
              }