]> Cypherpunks.ru repositories - gostls13.git/commit
cmd/compile: fix importing of method expressions
authorKeith Randall <khr@golang.org>
Tue, 13 Apr 2021 23:31:56 +0000 (16:31 -0700)
committerKeith Randall <khr@golang.org>
Wed, 14 Apr 2021 04:02:01 +0000 (04:02 +0000)
commit6d8ba77896d05720e1cb1728c27db60926e672b5
treec871ac85f8407be5df6b830df4fa8d6e57371131
parente7ab1a5ba83cd013af24b011d9d3a88dc5b05c07
cmd/compile: fix importing of method expressions

For OMETHEXPR, the Name in the Selection needs to be properly
linked up to the method declaration. Use the same code we
already have for ODOTMETH and OCALLPART to do that.

Fixes #45503

Change-Id: I7d6f886d606bae6faad8c104f50c177f871d41c8
Reviewed-on: https://go-review.googlesource.com/c/go/+/309831
Trust: Keith Randall <khr@golang.org>
Run-TryBot: Keith Randall <khr@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Cuong Manh Le <cuong.manhle.vn@gmail.com>
Reviewed-by: Dan Scales <danscales@google.com>
src/cmd/compile/internal/typecheck/iexport.go
src/cmd/compile/internal/typecheck/iimport.go
test/fixedbugs/issue45503.dir/a.go [new file with mode: 0644]
test/fixedbugs/issue45503.dir/b.go [new file with mode: 0644]
test/fixedbugs/issue45503.go [new file with mode: 0644]