-
-
Notifications
You must be signed in to change notification settings - Fork 378
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Fix hanging redundant import on Unicode function #2870
Conversation
Instead of using a low-level `is_ident` that only works on ascii characters. Instead match directly on the '_' character. The original functionality has been restored (using `isAlpha` instead). This commit removes the now unneccessary `is_ident` compat layer
6179208
to
528a8bd
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it worth adding a test?
I think that it makes sense to add a simple test based on the repro I reported in #2859 to make sure that the reported issue is actually solved by this PR. |
Will add one yes |
Regression test properly fails. Will timeout after some time, hope this is reasonable? |
* Revert partial changes from haskell#2483 Instead of using a low-level `is_ident` that only works on ascii characters. Instead match directly on the '_' character. The original functionality has been restored (using `isAlpha` instead). This commit removes the now unneccessary `is_ident` compat layer * Add regression test for unicode functions Co-authored-by: Pepe Iborra <pepeiborra@gmail.com> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
* Revert partial changes from haskell#2483 Instead of using a low-level `is_ident` that only works on ascii characters. Instead match directly on the '_' character. The original functionality has been restored (using `isAlpha` instead). This commit removes the now unneccessary `is_ident` compat layer * Add regression test for unicode functions Co-authored-by: Pepe Iborra <pepeiborra@gmail.com> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Closes #2859
Revert partial changes from #2483
For redundant import actions, the code path ends up calling
wrapOperatorInParen
which under the hood makes a call tois_ident
which is a low-levelChar -> Bool
. The function will panic when it's input falls out of ASCII range.The fix is just to match directly on the '_' character. Outside of this codepath, the original
functionality has been restored (using
isAlpha
).Also removes the now unnecessary
is_ident
compat layer.