beancount-gs/tests/main.go

18 lines
230 B
Go
Raw Permalink Normal View History

2021-11-19 09:54:02 +00:00
package tests
2021-11-21 14:37:13 +00:00
import (
"fmt"
"reflect"
)
2021-11-19 09:54:02 +00:00
type Student struct {
2021-11-21 14:37:13 +00:00
Name string
2021-11-19 09:54:02 +00:00
}
2021-11-21 14:37:13 +00:00
func Test(i interface{}) {
t := reflect.TypeOf(i)
k := t.Kind()
v := reflect.ValueOf(i)
fmt.Printf("type: %s, kind: %s, value: %s", t, k, v)
2021-11-19 09:54:02 +00:00
}