scanIgnoreWhitespace scans the next non-whitespace.
()
| 657 | |
| 658 | // scanIgnoreWhitespace scans the next non-whitespace. |
| 659 | func (p *Parser) scanIgnoreWhitespace() (tok token, pos int, lit string) { |
| 660 | for { |
| 661 | tok, pos, lit = p.scan() |
| 662 | if tok == WS { |
| 663 | continue |
| 664 | } |
| 665 | return |
| 666 | } |
| 667 | } |
| 668 | |
| 669 | // unscan pushes the previously read token back onto the buffer. |
| 670 | func (p *Parser) unscan() { p.s.unscan() } |
no test coverage detected