From 995f03a60513de980272f41dbcd6b6dae1e86c7c Mon Sep 17 00:00:00 2001 From: Cihangir SAVAS Date: Sun, 17 Aug 2014 02:51:18 -0700 Subject: [PATCH] Structs: fix documentation --- field.go | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/field.go b/field.go index 2758eeb..12fdd31 100644 --- a/field.go +++ b/field.go @@ -85,13 +85,14 @@ func (f *Field) Set(val interface{}) error { return nil } -// Fields returns a slice of Fields. A struct tag with the content of "-" -// ignores the checking of that particular field. Example: +// Fields returns a slice of Fields. This is particular handy to get the fields +// of a nested struct . A struct tag with the content of "-" ignores the +// checking of that particular field. Example: // // // Field is ignored by this package. -// Field bool `structs:"-"` +// Field *http.Request `structs:"-"` // -// It panics if s's kind is not struct. +// It panics if field is not exported or if field's kind is not struct func (f *Field) Fields() []*Field { return getFields(f.value) }