diff options
Diffstat (limited to 'lib/reflect/example_test.go')
| -rw-r--r-- | lib/reflect/example_test.go | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/reflect/example_test.go b/lib/reflect/example_test.go index c0b028a3..69970fea 100644 --- a/lib/reflect/example_test.go +++ b/lib/reflect/example_test.go @@ -458,13 +458,12 @@ func ExampleTag() { field reflect.StructField val string opts []string - x int hasTag bool ) vtype = reflect.TypeOf(t) - for x = 0; x < vtype.NumField(); x++ { + for x := range vtype.NumField() { field = vtype.Field(x) val, opts, hasTag = libreflect.Tag(field, "atag") fmt.Println(val, opts, hasTag) |
