Closed
Description
When the following program is run by the gc compiler it prints
in: 3; out: 0; variadic: true
When run by gccgo it prints
in: 3; out: 0; variadic: false
This is a bug somewhere in the gofrontend code.
package main
import (
"fmt"
"reflect"
)
type E struct{}
func (E) M(x string, xs ...int) {}
func main() {
t := reflect.TypeOf(E{})
for i := 0; i < t.NumMethod(); i++ {
tm := t.Method(i).Type
fmt.Printf("in: %d; out: %d; variadic: %t\n", tm.NumIn(), tm.NumOut(), tm.IsVariadic())
}
}