compiler: finalize methods for type aliases of struct types
authorIan Lance Taylor <iant@golang.org>
Fri, 28 Aug 2020 05:18:45 +0000 (22:18 -0700)
committerIan Lance Taylor <iant@golang.org>
Mon, 21 Sep 2020 22:53:48 +0000 (15:53 -0700)
commit27edc6c3e296a3eea15be291b1f605a647e94107
treec6e4455454a14fbbb33edc4c31d941cd9c0797eb
parent1e19ecd79b45af6df87a6869d1936b857c9f71fc
compiler: finalize methods for type aliases of struct types

Previously we would finalize the methods of the alias type itself, but
since its a type alias we really need to finalize the methods of the
aliased type.

Also, handle method expressions of unnamed struct types.

Test case is https://golang.org/cl/251168.

Fixes golang/go#38125

Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/251279
gcc/go/gofrontend/MERGE
gcc/go/gofrontend/expressions.cc
gcc/go/gofrontend/gogo.cc