From 07ca4481b0e7b4a0633f573b52c86bedef4eed2c Mon Sep 17 00:00:00 2001 From: tnextday Date: Mon, 22 Aug 2016 16:11:06 +0800 Subject: [PATCH] add todo --- g_docs.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/g_docs.go b/g_docs.go index 1be9fba..f6cf29f 100644 --- a/g_docs.go +++ b/g_docs.go @@ -615,6 +615,7 @@ func getModel(str string) (pkgpath, objectname string, m swagger.Schema, realTyp ColorLog("Unknown type without TypeSec: %v\n", d) os.Exit(1) } + // TODO support other types, such as `ArrayType`, `MapType`, `InterfaceType` etc... st, ok := ts.Type.(*ast.StructType) if !ok { continue @@ -704,7 +705,8 @@ func getModel(str string) (pkgpath, objectname string, m swagger.Schema, realTyp } } if m.Title == "" { - ColorLog("[ERRO]can't find the object: %s\n", str) + ColorLog("[WARN]can't find the object: %s\n", str) + // TODO remove when all type have been supported //os.Exit(1) } if len(rootapi.Definitions) == 0 {