blob: 7d292e0cc49027d2bafd3f6c9b418d3b8020de8e [file] [log] [blame]
// 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 p
// TODO(gri) Still need better error positions and message here.
// But this doesn't crash anymore.
func f[P /* ERROR does not match \*Q */ interface{*Q}, Q any](p P, q Q) {
_ = f[P]
_ = f[/* ERROR cannot infer P */ *P]
}