Files
Marc VertesandGitHub f4d7bc2684 interp: fix append of values to an array of interface objects
Interface wrappers were not properly generated.

Fixes #1185
2021-07-15 11:38:12 +02:00

21 lines
225 B
Go

package main
import "io"
type B []byte
func (b B) Write(p []byte) (n int, err error) {
b = p
return len(p), nil
}
func main() {
b := B{}
a := make([]io.Writer, 0)
a = append(a, b)
println(len(a))
}
// Output:
// 1