diff options
Diffstat (limited to 'vm/type.go')
| -rw-r--r-- | vm/type.go | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -95,8 +95,8 @@ func StructOf(fields []*Type) *Type { return &Type{Rtype: reflect.StructOf(rf)} } -// FieldNameIndex returns the index of struct field name. -func (t *Type) FieldNameIndex(name string) []int { +// FieldIndex returns the index of struct field name. +func (t *Type) FieldIndex(name string) []int { for _, f := range reflect.VisibleFields(t.Rtype) { if f.Name == name { return f.Index |
