These functions implement a simple scanner and parser which, though inefficient, are flexible and may be suitable for rapid prototyping.
Exported Functions | |
---|---|
eval/1 | |
parse/3 | Parses a list of tokens into a parse tree. |
scan/2 | Scans a string for tokens. |
test/0 | |
Internal Documented Functions | |
find_production_body/3 | Returns the most likely production from the given list of productions based on the name and the tokens. |
eval(Arg1) -> term()
parse([token()], [production()], production_name()) -> {ok, {[token()], parse_tree()}} | {error, Reason}
Parses a list of tokens into a parse tree.
scan(string(), [token_spec()]) -> {ok, [token()]} | {error, Reason}
Scans a string for tokens.
test() -> term()