ident returns the i'th token if it is an Ident, otherwise nil.
(i int)
| 655 | |
| 656 | // ident returns the i'th token if it is an Ident, otherwise nil. |
| 657 | func (p *parser) ident(i int) *Token { |
| 658 | if tok := p.tok(i); tok != nil && tok.Type == Ident { |
| 659 | return tok |
| 660 | } |
| 661 | return nil |
| 662 | } |
| 663 | |
| 664 | // pident returns the i'th token if it is an PIdent, otherwise nil. |
| 665 | func (p *parser) pident(i int) *Token { |