You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What behavior of the library made you think about the improvement?
Python's syntax isn't context-free due to indentation handling, it is context-sensitive.
It is impossible to create a CFGFSM with Python's production rules.
How would you like it to behave?
Lark provides functionality to extend beyond context-free grammars and can handle a subset of context-sensitive languages, including Python, thanks to lark.PostLex.
What behavior of the library made you think about the improvement?
Python's syntax isn't context-free due to indentation handling, it is context-sensitive.
It is impossible to create a
CFGFSM
with Python's production rules.How would you like it to behave?
Lark provides functionality to extend beyond context-free grammars and can handle a subset of context-sensitive languages, including Python, thanks to
lark.PostLex
.Example: https://github.com/lark-parser/lark/blob/master/examples/indented_tree.py#L30
Completion criteria
python3.lark
https://github.com/lark-parser/lark/blob/master/lark/grammars/python.larkpostlex
kwarg inCFGFSM
post_lex=PythonIndenter()
if the grammar has%declare _PYTHON_INDENT
PostLex
subclasses can be integrated where necessary, e.g.yaml
The text was updated successfully, but these errors were encountered: