txlyre před 3 hodinami
rodič
revize
1520e69e00
1 změnil soubory, kde provedl 5 přidání a 1 odebrání
  1. 5 1
      qic.c

+ 5 - 1
qic.c

@@ -7610,6 +7610,9 @@ void compile_node(buffer_t *gbuf, buffer_t *buf, list_t *ctx, table_t *ltab,
     {
       EMIT("%s", text);
     }
+    else if (text[0] && (text[strlen(text) - 1] == '{' || text[strlen(text) - 1] == '}')) {
+      EMIT("%s", text);
+    }
     else
     {
       EMIT("%s;", text);
@@ -7835,11 +7838,12 @@ int main(int argc, char **argv)
         fprintf(stderr, "qilang compiler, " QIC_VERSION "\n");
         fprintf(
             stderr,
-            "usage: %s [-dsh] [-o out.c] [input0.qi input1.qi ... inputN.qi]\n",
+            "usage: %s [-dsh] [-p prefix] [-o out.c] [input0.qi input1.qi ... inputN.qi]\n",
             argv[0]);
         fprintf(stderr, "-h --help\tprint this message and exit\n");
         fprintf(stderr, "-d --debug\tenable debug mode\n");
         fprintf(stderr, "-s --stdin\tread stdin as input\n");
+        fprintf(stderr, "-p --prefix\tset prefix for generated C names\n");
         fprintf(stderr,
                 "-o --output\toutput generated C code to the specified file\n");