Fix typo in generated comment for UnmarshalText

Currently, the generated code starts with "// MarshalText" even though
the method is "UnmarshalText".
This commit is contained in:
Prashant Varanasi 2018-04-09 18:09:18 -07:00
parent 70e5ffb726
commit 0fe51c2f54
2 changed files with 2 additions and 2 deletions

View File

@ -119,7 +119,7 @@ func (i %[1]s) MarshalText() ([]byte, error) {
return []byte(i.String()), nil
}
// MarshalText implements the encoding.TextUnmarshaler interface for %[1]s
// UnmarshalText implements the encoding.TextUnmarshaler interface for %[1]s
func (i *%[1]s) UnmarshalText(text []byte) error {
var err error
*i, err = %[1]sString(string(text))

View File

@ -660,7 +660,7 @@ func (i Prime) MarshalText() ([]byte, error) {
return []byte(i.String()), nil
}
// MarshalText implements the encoding.TextUnmarshaler interface for Prime
// UnmarshalText implements the encoding.TextUnmarshaler interface for Prime
func (i *Prime) UnmarshalText(text []byte) error {
var err error
*i, err = PrimeString(string(text))