Make certain parser function public so they can be used by outside packages
parent
96516fe6d9
commit
7d06250c1c
|
@ -64,7 +64,7 @@ func (t *ParseTree) Handle(tok Token, fn func(*Parser) (Statement, error)) {
|
|||
// Parse parses a statement using the language defined in the parse tree.
|
||||
func (t *ParseTree) Parse(p *Parser) (Statement, error) {
|
||||
for {
|
||||
tok, pos, lit := p.scanIgnoreWhitespace()
|
||||
tok, pos, lit := p.ScanIgnoreWhitespace()
|
||||
if subtree, ok := t.Tokens[tok]; ok {
|
||||
t = subtree
|
||||
continue
|
||||
|
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue