how does golang get the underlying type name?
give an example:
func Hello(w http.ResponseWriter, r *http.Request) {
io.WriteString(w, "hello")
}
h := http.HandlerFunc(Hello)
http.HandleFunc("/hello", h)
here through reflection h
I only get its name HandlerFunc
, and I want to get h
underlying type name Hello
what should I do?