diff options
author | Robert Griesemer <gri@golang.org> | 2021-07-28 15:29:19 -0700 |
---|---|---|
committer | Robert Griesemer <gri@golang.org> | 2021-07-29 21:05:45 +0000 |
commit | 27552e9172c5a9f7bbd8428c6e30eac14bb5e0b0 (patch) | |
tree | 725803dfd6ba089389abe0a83f9c83e0eeff6f6e /src/cmd/compile/internal/types2/sizeof_test.go | |
parent | af903261e7e6af8ce932433cf87a60381781bfb9 (diff) | |
download | go-27552e9172c5a9f7bbd8428c6e30eac14bb5e0b0.tar.gz go-27552e9172c5a9f7bbd8428c6e30eac14bb5e0b0.zip |
[dev.typeparams] cmd/compile: set type parameter indices when they are bound
This is a port of CL 336249 with adjustments due to slightly
different handling of type parameter declaration in types2.
The CL also contains adjustments to the compiler front-end.
With this change it is not necessary to export type parameter
indices. Filed issue #47451 so we don't forget.
Change-Id: I2834f7be313fcb4763dff2a9058f1983ee6a81b3
Reviewed-on: https://go-review.googlesource.com/c/go/+/338192
Trust: Robert Griesemer <gri@golang.org>
Run-TryBot: Robert Griesemer <gri@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Findley <rfindley@google.com>
Diffstat (limited to 'src/cmd/compile/internal/types2/sizeof_test.go')
-rw-r--r-- | src/cmd/compile/internal/types2/sizeof_test.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cmd/compile/internal/types2/sizeof_test.go b/src/cmd/compile/internal/types2/sizeof_test.go index 70cf3709e5..8255e6ded4 100644 --- a/src/cmd/compile/internal/types2/sizeof_test.go +++ b/src/cmd/compile/internal/types2/sizeof_test.go @@ -26,12 +26,12 @@ func TestSizeof(t *testing.T) { {Struct{}, 24, 48}, {Pointer{}, 8, 16}, {Tuple{}, 12, 24}, - {Signature{}, 44, 88}, + {Signature{}, 28, 56}, {Union{}, 12, 24}, {Interface{}, 40, 80}, {Map{}, 16, 32}, {Chan{}, 12, 24}, - {Named{}, 88, 168}, + {Named{}, 80, 152}, {TypeParam{}, 28, 48}, {term{}, 12, 24}, {top{}, 0, 0}, |