go/ast.GenDecl.Doc (field)
26 uses
go/ast (current package)
ast.go#L966: Doc *CommentGroup // associated documentation; or nil
walk.go#L327: if n.Doc != nil {
walk.go#L328: Walk(v, n.Doc)
go/build
read.go#L436: doc = d.Doc
go/doc
example.go#L329: if d.Doc != nil {
example.go#L330: comments = append(comments, d.Doc)
reader.go#L301: Doc: decl.Doc.Text(),
reader.go#L307: decl.Doc = nil // doc consumed - remove from AST
reader.go#L349: doc = decl.Doc
reader.go#L353: decl.Doc = nil // doc consumed - remove from AST
reader.go#L545: Doc: d.Doc,
go/parser
parser.go#L2423: Doc: doc,
go/printer
nodes.go#L1605: p.setComment(d.Doc)
printer.go#L1042: return n.Doc
golang.org/x/pkgsite/internal/godoc
encode_ast.gen.go#L1674: if x.Doc != nil {
encode_ast.gen.go#L1676: encode_ast_CommentGroup(e, x.Doc)
encode_ast.gen.go#L1719: decode_ast_CommentGroup(d, &x.Doc)
golang.org/x/pkgsite/internal/godoc/internal/doc
example.go#L263: if d.Doc != nil {
example.go#L264: comments = append(comments, d.Doc)
reader.go#L302: text := decl.Doc.Text()
reader.go#L311: decl.Doc = nil // doc consumed - remove from AST
reader.go#L353: doc = decl.Doc
reader.go#L357: decl.Doc = nil // doc consumed - remove from AST
reader.go#L549: Doc: d.Doc,
![]() |
The pages are generated with Golds v0.3.2-preview. (GOOS=darwin GOARCH=amd64) Golds is a Go 101 project developed by Tapir Liu. PR and bug reports are welcome and can be submitted to the issue list. Please follow @Go100and1 (reachable from the left QR code) to get the latest news of Golds. |