Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Lark backend #120

Open
Erotemic opened this issue Mar 25, 2022 · 0 comments
Open

Add Lark backend #120

Erotemic opened this issue Mar 25, 2022 · 0 comments

Comments

@Erotemic
Copy link
Owner

A Lark backend allows us to have a well defined grammar for parsing docstrings and extracting doctests.

It might not be faster than the current whatever-i-did-to-get-it-working approach. But mine may have edge cases that a proper grammar would not.

Something like:

start? docstring
doctest: indented(python, '>>>')
example_item: doctest
example_items: list(example_item)
args: "Args: " indented(args_items)
example: "Example: " indented(example_items)
ignore: "Ignore: " indented(text)
dockblock: args | example | ignore | benchmark | misc
docstring: text | docblock
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant