aboutsummaryrefslogtreecommitdiff
path: root/test/typeparam/aliasimp.go
diff options
context:
space:
mode:
authorDan Scales <danscales@google.com>2021-05-24 14:15:48 -0700
committerDan Scales <danscales@google.com>2021-05-26 21:38:54 +0000
commitb7f7d1cd7b3d965ec25d365b3e5057ef3278c729 (patch)
treee6a87b391b05e89d62714c9c0894188e6e312dca /test/typeparam/aliasimp.go
parent95748d1b741d2c612cf90d9b6f4f8bdb81800e23 (diff)
downloadgo-b7f7d1cd7b3d965ec25d365b3e5057ef3278c729.tar.gz
go-b7f7d1cd7b3d965ec25d365b3e5057ef3278c729.zip
[dev.typeparams] cmd/compile: get type aliases working with generic types
Generic types can the source type of a type alias, so modify g.typ0() to be able to deal with base generic types. Added test aliasimp.go that tests aliasing of local generic types and imported generic types. Change-Id: I1c398193819d47a36b014cc1f9bb55107e9a565b Reviewed-on: https://go-review.googlesource.com/c/go/+/322194 Trust: Dan Scales <danscales@google.com> Trust: Robert Griesemer <gri@golang.org> Reviewed-by: Robert Griesemer <gri@golang.org>
Diffstat (limited to 'test/typeparam/aliasimp.go')
-rw-r--r--test/typeparam/aliasimp.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/typeparam/aliasimp.go b/test/typeparam/aliasimp.go
new file mode 100644
index 0000000000..76930e5e4f
--- /dev/null
+++ b/test/typeparam/aliasimp.go
@@ -0,0 +1,7 @@
+// rundir -G=3
+
+// Copyright 2021 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package ignored