Text file src/go/types/testdata/fixedbugs/issue39768.go2
Documentation: go/types/testdata/fixedbugs
1 // Copyright 2020 The Go Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 package p 6 7 type T[P any] P 8 type A = T 9 var x A[int] 10 var _ A /* ERROR cannot use generic type */ 11 12 type B = T[int] 13 var y B = x 14 var _ B /* ERROR not a generic type */ [int] 15 16 // test case from issue 17 18 type Vector[T any] []T 19 type VectorAlias = Vector 20 var v Vector[int] 21