Files
cpp-thirdparty/winx64/bin/swigwin-4.0.0/Examples/test-suite/go/overload_extend_runme.go
2019-08-04 21:38:19 -05:00

23 lines
331 B
Go

package main
import "overload_extend"
func main() {
f := overload_extend.NewFoo()
if f.Test().(int) != 0 {
panic(0)
}
if f.Test(3).(int) != 1 {
panic(0)
}
if f.Test("hello").(int) != 2 {
panic(0)
}
if f.Test(float64(3), float64(2)).(float64) != 5 {
panic(0)
}
if f.Test(3.0).(float64) != 1003 {
panic(0)
}
}