go/ast.File.Comments (field)
21 uses
go/ast (current package)
ast.go#L1063: Comments []*CommentGroup // list of all comments in the source file
ast.go#L1114: for _, group := range file.Comments {
filter.go#L351: ncomments += len(f.Comments)
filter.go#L489: i += copy(comments[i:], f.Comments)
import.go#L138: first := len(f.Comments)
import.go#L140: for i, g := range f.Comments {
import.go#L158: comments = f.Comments[first : last+1]
go/build
read.go#L494: for _, group := range info.parsed.Comments {
go/doc
example.go#L85: output, unordered, hasOutput := exampleOutput(f.Body, file.Comments)
example.go#L91: Comments: file.Comments,
example.go#L269: for _, c := range file.Comments {
example.go#L324: Comments: comments,
example.go#L548: comments := file.Comments
example.go#L570: f.Comments = comments
reader.go#L644: r.readNotes(src.Comments)
reader.go#L646: src.Comments = nil // consumed unassociated comments - remove from AST
go/parser
parser.go#L2909: Comments: p.comments,
go/printer
printer.go#L1084: if len(n.Comments) > 0 {
printer.go#L1085: return n.Comments[len(n.Comments)-1]
printer.go#L1134: p.comments = n.Comments