go/types, types2: ensure we have an interface before checking constraints
Due to delayed computation of constraint type sets it is possible that a type argument is checked against a constraint before that constraint has been wrapped into an implicit interface (if needed). When the type checker is about to check whether a type argument implements a constraint, it's always safe to force wrapping of a constraint in an implicit interface (if necessary) before doing the implements check. Also, use a better position for tracing output related to constraint type set computation. Fixes #51048. Change-Id: I52fecbf57814f09b62762452d7e17c2a230fdd59 Reviewed-on: https://go-review.googlesource.com/c/go/+/383834 Trust: Robert Griesemer <gri@golang.org> Reviewed-by:Robert Findley <rfindley@google.com>
Loading
Please sign in to comment