• Home
  • Raw
  • Download

Lines Matching refs:scanner

31 	Pos scanner.Position
53 p.accept(scanner.EOF)
61 scanner scanner.Scanner member
72 p.scanner.Init(r)
73 p.scanner.Error = func(sc *scanner.Scanner, msg string) {
76 p.scanner.Whitespace = 0
77 p.scanner.IsIdentRune = func(ch rune, i int) bool {
82 p.scanner.Mode = scanner.ScanIdents
83 p.scanner.Filename = filename
88 func (p *parser) Unpack(pos Pos) scanner.Position {
91 return scanner.Position{
92 Filename: p.scanner.Filename,
100 pos := p.scanner.Position
102 pos = p.scanner.Pos()
110 Pos: p.scanner.Position,
121 p.errorf("expected %s, found %s", scanner.TokenString(tok),
122 scanner.TokenString(p.tok))
131 if p.tok != scanner.EOF {
132 p.tok = p.scanner.Scan()
134 p.tok = p.scanner.Scan()
138 p.lines = append(p.lines, p.scanner.Position.Offset+1)
179 case '#', '\n', scanner.EOF:
187 case scanner.EOF:
196 p.scanner.TokenText())
203 if p.tok != scanner.Ident || !isDirective(p.scanner.TokenText()) {
207 d := p.scanner.TokenText()
209 p.accept(scanner.Ident)
239 case scanner.Ident:
240 value.appendString(p.scanner.TokenText())
241 if p.scanner.TokenText() == "endef" {
242 p.accept(scanner.Ident)
245 p.accept(scanner.Ident)
251 case scanner.EOF:
253 scanner.TokenString(p.tok))
264 case scanner.EOF:
268 value.appendString(p.scanner.TokenText())
277 p.scanner.Mode = 0
279 p.scanner.Mode = scanner.ScanIdents
311 case scanner.Ident:
312 value.appendString(p.scanner.TokenText())
313 p.accept(scanner.Ident)
319 case scanner.EOF:
321 scanner.TokenString(p.tok))
338 case scanner.EOF:
347 value.appendString(p.scanner.TokenText())
370 case scanner.EOF:
372 scanner.TokenString(p.tok))
423 case scanner.EOF:
426 recipe += p.scanner.TokenText()
469 case scanner.EOF:
472 p.errorf("unexpected token %s after rule prerequisites", scanner.TokenString(p.tok))
493 comment += "\\" + p.scanner.TokenText()
498 case scanner.EOF:
501 comment += p.scanner.TokenText()
628 return ch != scanner.Ident && ch != ':' && ch != '=' && ch != '#'