]> thyrsus.com Git - cupl.git/commitdiff
Better jump label display.
authorEric S. Raymond <esr@thyrsus.com>
Fri, 11 Nov 1994 11:27:04 +0000 (11:27 +0000)
committerEric S. Raymond <esr@thyrsus.com>
Fri, 11 Nov 1994 11:27:04 +0000 (11:27 +0000)
interpret.c

index 784af46d5eaf11790214744588c9e168f485b0fd..3cecda69187c113426ec2118d1310bef8426d539 100644 (file)
@@ -43,8 +43,13 @@ static void prettyprint(node *tree, int indent)
     else if (tree->type == STRING)
        (void) printf("STRING: '%s'\n", tree->u.string);
     else if (tree->type == STATEMENT && indent > 0)
-       (void) printf("-> %s (STATEMENT %d)\n", 
-                     tree->car->car->u.string, tree->number);
+    {
+       if (tree->car->type == LABEL)
+           (void) printf("-> %s (STATEMENT %d)\n", 
+                         tree->car->car->u.string, tree->number);
+       else
+           (void) printf("-> STATEMENT %d\n", tree->number);
+    }
     else
     {
        if (tree->type == STATEMENT)