]> Cypherpunks repositories - gostls13.git/commit
cmd/compile, test: updated comments in crawler.go, added test
authorDan Scales <danscales@google.com>
Wed, 29 Dec 2021 02:40:12 +0000 (18:40 -0800)
committerDan Scales <danscales@google.com>
Mon, 10 Jan 2022 19:51:05 +0000 (19:51 +0000)
commit7de2249a08aab44c512d0ea86f50481d76e135f1
tree4bdd2ad91a8b9ab37c48e8d623f662f950257b3e
parent933f6685f7d33f3865d6ef062cbb0944d3f5d2fc
cmd/compile, test: updated comments in crawler.go, added test

Added a test to make sure that the private methods of a local generic
type are properly exported, if there is a global variable with that
type.

Added comments in crawler.go, to give more detail and to give more about
the overall purpose.

Fixed one place where t.isFullyInstantiated() should be replaced by
isPtrFullyInstantiated(t), so that we catch pointers to generic types
that may be used as a method receiver.

Change-Id: I9c42d14eb6ebe14d249df7c8fa39e889f7cd3f22
Reviewed-on: https://go-review.googlesource.com/c/go/+/374754
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
Trust: Dan Scales <danscales@google.com>
Run-TryBot: Dan Scales <danscales@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
src/cmd/compile/internal/typecheck/crawler.go
test/typeparam/gencrawler.dir/a.go [new file with mode: 0644]
test/typeparam/gencrawler.dir/main.go [new file with mode: 0644]
test/typeparam/gencrawler.go [new file with mode: 0644]
test/typeparam/gencrawler.out [new file with mode: 0644]