File tree Expand file tree Collapse file tree 2 files changed +3
-0
lines changed Expand file tree Collapse file tree 2 files changed +3
-0
lines changed Original file line number Diff line number Diff line change @@ -48,6 +48,7 @@ type Marshaler interface {
48
48
// The XML element for a struct contains marshalled elements for each of the
49
49
// exported fields of the struct, with these exceptions:
50
50
// - the XMLName field, described above, is omitted.
51
+ // - a field with tag "-" is omitted.
51
52
// - a field with tag "name,attr" becomes an attribute with
52
53
// the given name in the XML element.
53
54
// - a field with tag ",attr" becomes an attribute with the
Original file line number Diff line number Diff line change @@ -132,6 +132,8 @@ import (
132
132
// of the above rules and the struct has a field with tag ",any",
133
133
// unmarshal maps the sub-element to that struct field.
134
134
//
135
+ // * A struct field with tag "-" is never unmarshalled into.
136
+ //
135
137
// Unmarshal maps an XML element to a string or []byte by saving the
136
138
// concatenation of that element's character data in the string or
137
139
// []byte. The saved []byte is never nil.
You can’t perform that action at this time.
0 commit comments