]> Cypherpunks repositories - gostls13.git/commit
[dev.typeparams] Separate out gcshape types that are instantiated types
authorDan Scales <danscales@google.com>
Fri, 9 Jul 2021 23:27:22 +0000 (16:27 -0700)
committerDan Scales <danscales@google.com>
Mon, 19 Jul 2021 05:02:24 +0000 (05:02 +0000)
commit9b85985d36a7cc7117e9c14bc1d2632844a5a818
tree7c7bb5da384fca45fbc1b2d9f37bc660629725b5
parentdf778e6fd9a8ad4f50f734f08b8d07d4ce597c02
[dev.typeparams] Separate out gcshape types that are instantiated types

Distinguish the gcshape of all top-level instantiated type from normal
concrete types, even if they have the exact same underlying "shape",
because in a function instantiation, any method call on this type arg
will be a generic method call (requiring a dictionary), rather than a
direct method call on the underlying type (no dictionary).

So, we add the instshape prefix to the gcshape name for instantiated
types, and we make it a defined type with that name.

Change-Id: I33056269d24f3451a2632a5ce6a481108f533c9c
Reviewed-on: https://go-review.googlesource.com/c/go/+/335169
Trust: Dan Scales <danscales@google.com>
Run-TryBot: Dan Scales <danscales@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Keith Randall <khr@golang.org>
src/cmd/compile/internal/noder/stencil.go