git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12108 626c5289-ae23-0410-ae9c-e8d60b6d4f22
22 lines
342 B
Go
22 lines
342 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(float64(3.0)).(float64) != 1003 {
|
|
panic(0)
|
|
}
|
|
}
|