closeCurlyBrace expects the current token to be a closing curly brace. This acts like an assertion because it returns an error if the token is not a closing curly brace. It does NOT advance the token.
()
| 713 | // because it returns an error if the token is not |
| 714 | // a closing curly brace. It does NOT advance the token. |
| 715 | func (p *parser) closeCurlyBrace() error { |
| 716 | if p.Val() != "}" { |
| 717 | return p.SyntaxErr("}") |
| 718 | } |
| 719 | return nil |
| 720 | } |
| 721 | |
| 722 | func (p *parser) isNamedRoute() (bool, string) { |
| 723 | keys := p.block.Keys |
no test coverage detected