diff --git a/generate/swaggergen/g_docs.go b/generate/swaggergen/g_docs.go index a9f1c0a..d6c676b 100644 --- a/generate/swaggergen/g_docs.go +++ b/generate/swaggergen/g_docs.go @@ -880,7 +880,11 @@ func typeAnalyser(f *ast.Field) (isSlice bool, realType, swaggerType string) { } switch t := f.Type.(type) { case *ast.StarExpr: - return false, fmt.Sprint(t.X), "object" + basicType := fmt.Sprint(t.X) + if k, ok := basicTypes[basicType]; ok { + return false, basicType, k + } + return false, basicType, "object" case *ast.MapType: val := fmt.Sprintf("%v", t.Value) if isBasicType(val) {