// typelinks2 for 1.7 ~ //go:linkname typelinks2 reflect.typelinks func typelinks2() (sections []unsafe.Pointer, offset [][]int32) var initOnce … var types … var packages … // discoverTypes initializes types and packages func discoverTypes() { … } func loadGoTypes() { … } type emptyInterface … // TypeByName return the type by its name, just like Class.forName in java func TypeByName(typeName string) Type { … } // TypeByPackageName return the type by its package and name func TypeByPackageName(pkgPath string, name string) Type { … }