goose: skip function body type-checking
Learn this one weird trick to make goose an order of magnitude faster! Reviewed-by: Herbie Ong <herbie@google.com> Reviewed-by: Tuo Shan <shantuo@google.com>
This commit is contained in:
@@ -28,6 +28,7 @@ func Generate(bctx *build.Context, wd string, pkg string) ([]byte, error) {
|
|||||||
Build: new(build.Context),
|
Build: new(build.Context),
|
||||||
ParserMode: parser.ParseComments,
|
ParserMode: parser.ParseComments,
|
||||||
Cwd: wd,
|
Cwd: wd,
|
||||||
|
TypeCheckFuncBodies: func(string) bool { return false },
|
||||||
}
|
}
|
||||||
*conf.Build = *bctx
|
*conf.Build = *bctx
|
||||||
n := len(conf.Build.BuildTags)
|
n := len(conf.Build.BuildTags)
|
||||||
|
|||||||
Reference in New Issue
Block a user