1 // Copyright 2022 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 // As of issue #51527, type-type inference has been disabled.
8
9 type RC[RG any] interface {
10 ~[]RG
11 }
12
13 type Fn[RCT RC[RG], RG any] func(RCT)
14
15 type FFn[RCT RC[RG], RG any] func() Fn /* ERROR got 1 arguments */ [RCT]
16
17 type F[RCT RC[RG], RG any] interface {
18 Fn() Fn /* ERROR got 1 arguments */ [RCT]
19 }
20
21 type concreteF[RCT RC[RG], RG any] struct {
22 makeFn FFn /* ERROR got 1 arguments */ [RCT]
23 }
24
25 func (c *concreteF[RCT, RG]) Fn() Fn /* ERROR got 1 arguments */ [RCT] {
26 return c.makeFn()
27 }
28
View as plain text