parserString parses a string.
()
| 176 | |
| 177 | // parserString parses a string. |
| 178 | func (p *Parser) parseString() (string, error) { |
| 179 | tok, pos, lit := p.scanIgnoreWhitespace() |
| 180 | if tok != STRING { |
| 181 | return "", newParseError(tokstr(tok, lit), []string{"string"}, pos) |
| 182 | } |
| 183 | return lit, nil |
| 184 | } |
| 185 | |
| 186 | // peekRune returns the next rune that would be read by the scanner. |
| 187 | func (p *Parser) peekRune() rune { |
nothing calls this directly
no test coverage detected