Signed-off-by: Alejandro Mery <amery@jpi.io>
This commit is contained in:
2023-08-30 23:50:34 +01:00
parent 8907575b1d
commit 78d20c1359
3 changed files with 86 additions and 15 deletions
+4
View File
@@ -13,3 +13,7 @@ func (p *Parser) emitError(content string, err error) (lexer.StateFn, error) {
return nil, err
}
}
func (p *Parser) emitInvalidRune(r rune) (lexer.StateFn, error) {
return p.emitError(string([]rune{r}), lexer.ErrUnacceptableRune)
}