Line returns a line from the parser without advancing it. A delta of 0 returns the current line, while higher deltas return read-ahead lines. It returns an empty string if the delta is higher than the available lines, either because of the buffer size or because the parser reached the end of the inp
(delta uint)
| 133 | // either because of the buffer size or because the parser reached the end of |
| 134 | // the input. Valid lines always contain at least a newline character. |
| 135 | func (p *parser) Line(delta uint) string { |
| 136 | return p.lines[delta] |
| 137 | } |
| 138 | |
| 139 | // Errorf generates an error and appends the current line information. |
| 140 | func (p *parser) Errorf(delta int64, msg string, args ...interface{}) error { |
no outgoing calls