I\'m noob in Go :) so my question may be stupid, but can\'t find answer, so.
I need a function:
func name (v interface{}) { if is_slice() {
icza's answer is correct, but is not recommended by go creators:
interface{} says nothing
A better approach may be to define a function for each type you have:
func name(v MyInterface) { // do something } func names(vs []MyInterface) { for _, v := range(vs) { name(v) } }