From: Keith Randall Date: Tue, 16 Sep 2014 19:50:05 +0000 (-0700) Subject: runtime: make it clear that Goexit cannot be recover'd. X-Git-Tag: go1.4beta1~391 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=15274e5c9bd5393f67a77200f0669ab00f2ab0ed;p=gostls13.git runtime: make it clear that Goexit cannot be recover'd. LGTM=r R=r, bradfitz, khr CC=golang-codereviews https://golang.org/cl/136660044 --- diff --git a/src/runtime/panic.go b/src/runtime/panic.go index 12c85e7caf..927b6db44b 100644 --- a/src/runtime/panic.go +++ b/src/runtime/panic.go @@ -238,7 +238,8 @@ func deferreturn(arg0 uintptr) { } // Goexit terminates the goroutine that calls it. No other goroutine is affected. -// Goexit runs all deferred calls before terminating the goroutine. +// Goexit runs all deferred calls before terminating the goroutine. Because Goexit +// is not panic, however, any recover calls in those deferred functions will return nil. // // Calling Goexit from the main goroutine terminates that goroutine // without func main returning. Since func main has not returned,