From: Rob Pike Date: Wed, 6 May 2015 20:45:03 +0000 (-0700) Subject: cmd/doc: add type-bound vars to global vars list X-Git-Tag: go1.5beta1~699 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=da4fc529d924e796976ea22b928533c8973fdb71;p=gostls13.git cmd/doc: add type-bound vars to global vars list Already done for constants and funcs, but I didn't realize that some global vars were also not in the global list. This fixes go doc build.Default Change-Id: I768bde13a400259df3e46dddc9f58c8f0e993c72 Reviewed-on: https://go-review.googlesource.com/9764 Reviewed-by: Andrew Gerrand --- diff --git a/src/cmd/doc/pkg.go b/src/cmd/doc/pkg.go index d52dd97864..3a0aa7ff89 100644 --- a/src/cmd/doc/pkg.go +++ b/src/cmd/doc/pkg.go @@ -71,6 +71,7 @@ func parsePackage(pkg *build.Package, userPath string) *Package { docPkg := doc.New(astPkg, pkg.ImportPath, doc.AllDecls) for _, typ := range docPkg.Types { docPkg.Consts = append(docPkg.Consts, typ.Consts...) + docPkg.Vars = append(docPkg.Vars, typ.Vars...) docPkg.Funcs = append(docPkg.Funcs, typ.Funcs...) }