aboutsummaryrefslogtreecommitdiff
path: root/test/codegen
diff options
context:
space:
mode:
authorThan McIntosh <thanm@google.com>2023-05-03 12:38:50 -0400
committerThan McIntosh <thanm@google.com>2023-05-05 21:04:38 +0000
commit89138ce740bf72c7a6c0eae5aa281f10094637cf (patch)
tree92afdaa6f9cf51e82ee93e258b6ab237790f3176 /test/codegen
parentea69de9b921a1c1abbfe82012194c8e946e14cfd (diff)
downloadgo-89138ce740bf72c7a6c0eae5aa281f10094637cf.tar.xz
cmd/compile: un-hide closure func if parent expr moved to staticinit
If the function referenced by a closure expression is incorporated into a static init, be sure to mark it as non-hidden, since otherwise it will be live but no longer reachable from the init func, hence it will be skipped during escape analysis, which can lead to miscompilations. Fixes #59680. Change-Id: Ib858aee296efcc0b7655d25c23ab8a6a8dbdc5f9 Reviewed-on: https://go-review.googlesource.com/c/go/+/492135 TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Cherry Mui <cherryyz@google.com> Reviewed-by: Matthew Dempsky <mdempsky@google.com> Run-TryBot: Than McIntosh <thanm@google.com> Reviewed-by: Cuong Manh Le <cuong.manhle.vn@gmail.com>
Diffstat (limited to 'test/codegen')
0 files changed, 0 insertions, 0 deletions