|
|
@ -3733,7 +3733,6 @@ void outputTree(oop node, int depth) |
|
|
|
} |
|
|
|
#undef CASE |
|
|
|
#undef OUT |
|
|
|
//outputTree(map_get(node, comment_symbol), depth); // if we want to print comments |
|
|
|
} |
|
|
|
|
|
|
|
void printTree() { |
|
|
@ -3741,6 +3740,8 @@ void printTree() { |
|
|
|
printf("\n"); |
|
|
|
} |
|
|
|
|
|
|
|
int toPrint = 0; |
|
|
|
|
|
|
|
int main(int argc, char **argv) |
|
|
|
{ |
|
|
|
# if (USE_GC) |
|
|
@ -3798,13 +3799,19 @@ int main(int argc, char **argv) |
|
|
|
#undef _DO |
|
|
|
|
|
|
|
|
|
|
|
/* Checking arguments */ |
|
|
|
while (argc-- > 1) { |
|
|
|
++argv; |
|
|
|
if (!strcmp(*argv, "-t")) toPrint = 1; |
|
|
|
} |
|
|
|
|
|
|
|
/* File scope */ |
|
|
|
pushScope(); |
|
|
|
|
|
|
|
inputStackPush(NULL); |
|
|
|
while (yyparse()) { |
|
|
|
outputNode(yylval); |
|
|
|
//printTree(); |
|
|
|
if (toPrint) printTree(); |
|
|
|
else outputNode(yylval); |
|
|
|
} |
|
|
|
|
|
|
|
popScope(); |
|
|
@ -3818,6 +3825,7 @@ int main(int argc, char **argv) |
|
|
|
++argv; |
|
|
|
if (!strcmp(*argv, "-g")) ++opt_g; |
|
|
|
else if (!strcmp(*argv, "-v")) ++opt_v; |
|
|
|
else if (!strcmp(*argv, "-t")) toPrint = 1; |
|
|
|
else if (!strcmp(*argv, "-")) { |
|
|
|
readEvalPrint(globals, NULL); |
|
|
|
repled= 1; |
|
|
|