Source file src/internal/types/testdata/fixedbugs/issue48312.go
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 type T interface{ m() } 8 type P *T 9 10 func _(p *T) { 11 p.m /* ERROR "type *T is pointer to interface, not interface" */ () 12 } 13 14 func _(p P) { 15 p.m /* ERROR "type P is pointer to interface, not interface" */ () 16 } 17 18 func _[P T](p *P) { 19 p.m /* ERROR "type *P is pointer to type parameter, not type parameter" */ () 20 } 21