if m.Tag != nil && m.Tag.Op() == ir.OTYPESW {
break // Nothing to do here for type switches.
}
- if m.Tag != nil && !m.Tag.Type().IsInterface() && m.Tag.Type().HasShape() {
+ if m.Tag != nil && !m.Tag.Type().IsEmptyInterface() && m.Tag.Type().HasShape() {
// To implement a switch on a value that is or has a type parameter, we first convert
// that thing we're switching on to an interface{}.
m.Tag = assignconvfn(m.Tag, types.Types[types.TINTER])
for i, x := range c.List {
// If we have a case that is or has a type parameter, convert that case
// to an interface{}.
- if !x.Type().IsInterface() && x.Type().HasShape() {
+ if !x.Type().IsEmptyInterface() && x.Type().HasShape() {
c.List[i] = assignconvfn(x, types.Types[types.TINTER])
}
}
"typeparam/nested.go", // 1.18 compiler doesn't support function-local types with generics
"typeparam/issue51521.go", // 1.18 compiler produces bad panic message and link error
"typeparam/issue53419.go", // 1.18 compiler mishandles generic selector resolution
- "typeparam/issue53477.go", // 1.18 compiler mishandles generic interface-interface comparisons from value switch statements
)
// In all of these cases, the 1.17 compiler reports reasonable errors, but either the