X-Git-Url: https://ocean-lang.org/code/?p=ocean;a=blobdiff_plain;f=csrc%2Fparsergen.mdc;h=709a9acb962e8be130030d7d7d183c2fb3222ed2;hp=076f3823941a20c4abb05237da892bc726d70266;hb=4e76641ba6fa31b2cafb16b2452f585ba70a6822;hpb=212f45a62c9e8a05a5df6b9e933619a86a9bd05b diff --git a/csrc/parsergen.mdc b/csrc/parsergen.mdc index 076f382..709a9ac 100644 --- a/csrc/parsergen.mdc +++ b/csrc/parsergen.mdc @@ -1969,9 +1969,9 @@ The go to table is stored in a simple array of `sym` and corresponding short result_size; }; struct state { + short reduce_prod; short go_to_cnt; const struct lookup * go_to; - short reduce_prod; }; ###### functions @@ -2039,10 +2039,10 @@ The go to table is stored in a simple array of `sym` and corresponding } } if (is->go_to.cnt) - fprintf(f, "\t[%d] = { %d, goto_%d, %d },\n", - i, is->go_to.cnt, i, prod); + fprintf(f, "\t[%d] = { %d, %d, goto_%d },\n", + i, prod, is->go_to.cnt, i); else - fprintf(f, "\t[%d] = { 0, NULL, %d },\n", i, prod); + fprintf(f, "\t[%d] = { %d, 0, NULL },\n", i, prod); } fprintf(f, "};\n\n"); }