This commit is contained in:
Terry Ding 2017-12-28 00:47:14 +08:00
parent 4ab8b8e30e
commit d70cedc7de
1 changed files with 2 additions and 0 deletions

View File

@ -1225,6 +1225,8 @@ func str2RealType(s string, typ string) interface{} {
switch typ {
case "int", "int64", "int32", "int16", "int8":
ret, err = strconv.Atoi(s)
case "uint", "uint64", "uint32", "uint16", "uint8":
ret, err = strconv.ParseUint(s, 10, 0)
case "bool":
ret, err = strconv.ParseBool(s)
case "float64":