-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Drop uppercase F32 and F64 float number suffixes #8782
Conversation
f51371a
to
c904103
Compare
Hmm, I'm not able to locate which test case fails on CircleCI.
|
As far as I know, this is intended. Type suffixes use only lower case characters. That also affects all similar identifiers. What makes you think this needs to support upper case? test_alpine failing is not related to this PR, you can ignore it. |
It seems |
Actually crystal/src/compiler/crystal/syntax/lexer.cr Line 1470 in 5519fbd
So I thought 'F' should be accepted in the case of I agree that uppercase suffix looks weird. There is no test for But it is a breaking change. Should we do it? I'm sorry that I'm not understanding how Crystal dev team currently makes a decision around breaking changes. If we should do, I'll update this PR to drop the uppercase |
Yes, I think we should drop |
OK, I'll update this branch tonight. |
I modified this PR for dropping the uppercase suffixes. And I also added small tests for invalid float number suffixes. Would you review this? |
I'm almost sure upper case characters are unlikely to be in use somewhere. But we should at least consider a deprecation path, either updating the formatter first or providing a deprecation message when an upper case character is encountered. |
If some shard is using I'm fine with merging this right away. |
CI fails due to #8782 (comment) but it seems not related to changes in this PR since in other PR it also fails with the same error. It's weird that #8781 does not cause the error, tho. |
With Crystal 0.32.1,
This PR fixesEDIT: We decided to drop uppercase suffixes. Please see following discussion.0F32
not to cause an error.