-
Notifications
You must be signed in to change notification settings - Fork 18.6k
Closed
Labels
FrozenDueToAgeNeedsFixThe path to resolution is known, but the work has not been done.The path to resolution is known, but the work has not been done.release-blocker
Milestone
Description
What version of Go are you using (go version)?
$ go version go version go1.17.2 linux/amd64
Does this issue reproduce with the latest release?
Yes
What did you do?
package main
func main() {
defer func() {
println(recover().(int))
}()
func() {
func() (_ [2]int) { type _ int; return }()
func() {
defer func() {
defer func() {
recover()
}()
defer panic(3)
panic(2)
}()
defer func() {
recover()
}()
panic(1)
}()
defer func() {}()
}()
var x = 123
func() {
defer print(x) // not executed!
func() {
defer func() {}()
panic(4)
}()
}()
}What did you expect to see?
Prints 1234.
What did you see instead?
Prints 4.
This issue is created by @ianlancetaylor's suggestion.
Metadata
Metadata
Assignees
Labels
FrozenDueToAgeNeedsFixThe path to resolution is known, but the work has not been done.The path to resolution is known, but the work has not been done.release-blocker