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

Very slow parsing of certain grammars #279

Open
hansihe opened this issue Sep 16, 2018 · 1 comment
Open

Very slow parsing of certain grammars #279

hansihe opened this issue Sep 16, 2018 · 1 comment

Comments

@hansihe
Copy link

hansihe commented Sep 16, 2018

When running on certain grammars (Like this), parsing takes extremely long. Even simple rules like digit in the file linked takes over 20 seconds to finish.

Removing both the whitespace and comment rules does nothing to improve the runtime. Changing the size of the input doesn't seem to change much either Tests were done through the debugger.

This is probably me doing something stupid, and I appreciate any feedback you can provide.

@dragostis
Copy link
Contributor

Seems odd that simple examples are running so slowly. There was a degenerate case that was slow a while ago, but it fixed on master, but that's definitely unrelate to why digit might be slow. I'll try to look into it soon. In the meantime, you could try to port this to pest 2.0 (master branch) and see if the same thing happens there. The differences between versions are quite small. Feel free to also reach for help on Gitter or build the 2.0 docs & book locally since they have been updated.

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

2 participants