MCPcopy Create free account
hub / github.com/vektah/gqlparser / consumeComment

Method consumeComment

parser/parser.go:32–45  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

30}
31
32func (p *parser) consumeComment() (*ast.Comment, bool) {
33 if p.err != nil {
34 return nil, false
35 }
36 tok := p.peek()
37 if tok.Kind != lexer.Comment {
38 return nil, false
39 }
40 p.next()
41 return &ast.Comment{
42 Value: tok.Value,
43 Position: &tok.Pos,
44 }, true
45}
46
47func (p *parser) consumeCommentGroup() {
48 if p.err != nil {

Callers 1

consumeCommentGroupMethod · 0.95

Calls 2

peekMethod · 0.95
nextMethod · 0.95

Tested by

no test coverage detected