]> Cypherpunks repositories - gostls13.git/commitdiff
runtime: fix and improve comments
authorDmitriy Vyukov <dvyukov@google.com>
Thu, 27 Feb 2014 16:27:55 +0000 (20:27 +0400)
committerDmitriy Vyukov <dvyukov@google.com>
Thu, 27 Feb 2014 16:27:55 +0000 (20:27 +0400)
LGTM=r
R=golang-codereviews, r
CC=golang-codereviews, iant, khr, rsc
https://golang.org/cl/67460043

src/pkg/runtime/panic.c

index 6e5be3e67751abc658bba31643f4faac5aeb8ca5..ffb4031ec9023d4de50f05a21283007e09d7752b 100644 (file)
@@ -226,7 +226,7 @@ runtime·panic(Eface e)
                        break;
                // take defer off list in case of recursive panic
                g->defer = d->link;
-               g->ispanic = true;      // rock for newstack, where reflect.newstackcall ends up
+               g->ispanic = true;      // rock for runtime·newstack, where runtime·newstackcall ends up
                argp = d->argp;
                pc = d->pc;
                runtime·newstackcall(d->fn, (byte*)d->args, d->siz);
@@ -246,7 +246,8 @@ runtime·panic(Eface e)
        // ran out of deferred calls - old-school panic now
        runtime·startpanic();
        printpanics(g->panic);
-       runtime·dopanic(0);
+       runtime·dopanic(0);    // should not return
+       runtime·exit(1);       // not reached
 }
 
 // Unwind the stack after a deferred function calls recover