Add support for maps.

This commit is contained in:
Alec Thomas
2018-06-13 22:16:43 +10:00
parent 54386f7fa5
commit ecf21e4cc9
7 changed files with 76 additions and 22 deletions
-8
View File
@@ -130,14 +130,6 @@ func parseTag(fv reflect.Value, ft reflect.StructField) *Tag {
t.Hidden = t.Has("hidden")
t.Format, _ = t.Get("format")
t.Sep, _ = t.GetRune("sep")
if t.Sep == 0 {
if t.Cmd || t.Arg {
t.Sep = ' '
} else {
t.Sep = ','
}
}
t.PlaceHolder, _ = t.Get("placeholder")
if t.PlaceHolder == "" {
t.PlaceHolder = strings.ToUpper(dashedString(fv.Type().Name()))