8000 Remove unused rules by hildjj · Pull Request #594 · peggyjs/peggy · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Remove unused rules #594

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

Merged
merged 1 commit into from
Apr 15, 2025
Merged

Remove unused rules #594

merged 1 commit into from
Apr 15, 2025

Conversation

hildjj
Copy link
Contributor
@hildjj hildjj commented Apr 10, 2025

Remove superfluous rules, merged character classes, and proxy rules all at the same time, by following the call graph from allowedStartRules after other modifications have been done. Hopefully this isn't O(n^2); I'm pretty sure it's just O(n) due to checking to see if we have already checked a given rule. Infinite loops shouldn't be possible due to them having been caught by report-infinite-recursion and report-infinite-repetition.

This patch builds on #593, and will be rebased on top of it before landing. It removes the previous attempt at adding proxies in that patch.

@hildjj hildjj force-pushed the remove-unused branch 4 times, most recently from a0d3032 to 29d24d4 Compare April 11, 2025 10:05
@hildjj hildjj marked this pull request as ready for review April 11, 2025 10:08
@hildjj hildjj force-pushed the remove-unused branch 3 times, most recently from 1b0cd5c to 8a1b389 Compare April 15, 2025 16:09
@hildjj
Copy link
Contributor Author
hildjj commented Apr 15, 2025

Removed the name->rule caching, since it didn't seem to affect performance at all.

@hildjj hildjj merged commit 8332243 into peggyjs:main Apr 15, 2025
10 checks passed
@hildjj hildjj deleted the remove-unused branch April 15, 2025 16:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant
0