commit bb62eb750a4a55634e242500fdb955278723805e
Author:     Roberto E. Vargas Caballero <[email protected]>
AuthorDate: Sun Sep 27 10:22:47 2015 +0200
Commit:     Roberto E. Vargas Caballero <[email protected]>
CommitDate: Sun Sep 27 10:22:47 2015 +0200

    Add better debug output in dumpstab

diff --git a/cc1/symbol.c b/cc1/symbol.c
index 2de75b3..318311a 100644
--- a/cc1/symbol.c
+++ b/cc1/symbol.c
@@ -29,15 +29,15 @@ dumpstab(char *msg)
                        continue;
                fprintf(stderr, "%d", (int) (bp - htab));
                for (sym = *bp; sym; sym = sym->hash)
-                       fprintf(stderr, "->[%d,%d:%s]",
-                               sym->ns, sym->ctx, sym->name);
+                       fprintf(stderr, "->[%d,%d:'%s'=%p]",
+                               sym->ns, sym->ctx, sym->name, (void *) sym);
                putc('\n', stderr);
        }
        fputs("head:", stderr);
        for (sym = head; sym; sym = sym->next) {
-               fprintf(stderr, "->[%d,%d:'%s']",
+               fprintf(stderr, "->[%d,%d:'%s'=%p]",
                        sym->ns, sym->ctx,
-                       (sym->name) ? sym->name : "");
+                       (sym->name) ? sym->name : "", (void *) sym);
        }
        putc('\n', stderr);
 }

Reply via email to