]> Cypherpunks repositories - gostls13.git/commit
cmd/compile: fixing 15.go for -G=3
authorDan Scales <danscales@google.com>
Sun, 22 Aug 2021 20:34:22 +0000 (13:34 -0700)
committerDan Scales <danscales@google.com>
Mon, 23 Aug 2021 16:57:27 +0000 (16:57 +0000)
commitf457ecc7f096c7e6b225003b583b989384ef0fcb
tree5462a743116a6264ae55e5b64b63ed71c2a987b5
parentf1d8ea1da3ef814ea57b545fc967865640a868ab
cmd/compile: fixing 15.go for -G=3

Required two changes:

 - avoid creating a closure in the case where the actual receiver of an
   embedded method is not generic even though the base operand of the
   selector is generic. This is similar to the test suggested by wayne
   zuo - I thought it was clear in buildClosure, and easier to comment.

 - Propagate //go:nointerface to base generic methods and then to
   instantiations.

Change-Id: If30c834e4223c2639b7f7e74d44e6087aa9ccd76
Reviewed-on: https://go-review.googlesource.com/c/go/+/344251
Run-TryBot: Dan Scales <danscales@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Wayne Zuo <wdvxdr1123@gmail.com>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
Trust: Dan Scales <danscales@google.com>
src/cmd/compile/internal/noder/decl.go
src/cmd/compile/internal/noder/stencil.go
test/run.go