-
-
Notifications
You must be signed in to change notification settings - Fork 417
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
Earley now uses OrderedSet for better output stability #1327
Conversation
17dbcfa
to
40228c6
Compare
@MegaIng @chanicpanic This change makes Earley approx 10% slower. (on a very simple benchmark) Do you think the stability it provides is worth it? (let's assume it gives us 100% output stability) |
Maybe have an option that can change it, but default to the slower, stable version? Also, I didn't check that this actually hits all locations, I assume you just searched for references to |
I like the idea of having an option to enable/disable it. Defaulting to the stable version would be more user-friendly. The slowdown is unfortunate, but it is consistent with Lark positioning Earley as the parser for power and LALR as the parser for speed. On the other hand, in addition to performance, it could be argued that defaulting to the unstable version has the benefit of exposing undesirable ambiguity and forcing grammar authors to remove/resolve it. |
b0c4fed
to
088197e
Compare
Codecov ReportPatch coverage:
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## master #1327 +/- ##
==========================================
+ Coverage 89.23% 89.26% +0.02%
==========================================
Files 51 51
Lines 7591 7612 +21
==========================================
+ Hits 6774 6795 +21
Misses 817 817
Flags with carried forward coverage won't be shown. Click here to find out more.
☔ View full report in Codecov by Sentry. |
@MegaIng @chanicpanic take 2 |
Addresses issue #1325, and others