-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Implement SIP-42 - Support for binary integer literals #19405
Conversation
Is it in the Scala 2 spec? If not we need a doc page for the change. As often docs are harder than code. |
I had forgotten that I forward-ported the commented code with other fixes. The old NthPortal PR was https://github.com/scala/scala/pull/8275/files which had only the syntax summary tweak. It has some more tests. Nth's comment:
That effort was in the six months leading up to the pandemic. My opinion is that it was unfortunate to put Scala 3 uptake in the path of Scala 2. That is, |
here is the relevant doc section to update: https://scala-lang.org/files/archive/spec/3.4/01-lexical-syntax.html#integer-literals |
Plus, we should have a short doc page in the docs/_docs/reference pages explaining the feature with a short example. We do that for all features that are new in Scala 3. |
I was expecting it to get backported to Scala 2, since there is already an implementation targetting it, will this not be the case ? |
@Sporarum that is likely. scala/scala#10656 |
But in any case we need a doc page to explain the new feature, whether it will be in Scala 2 or not. It should not be hard... |
@odersky |
I think it should have an entry here: https://dotty.epfl.ch/docs/reference/index.html Local directory is docs/_docs/reference. |
Note that the Scala 2 PR is now merged (for release in Scala 2.13.13). |
I have added a short reference page, let me know if something is missing |
I added the line to the second sidebar, and updated the Scala 3 Spec (I mistook the earlier message with one speaking about the Scala 2 Spec) If it's good like that, let me know and I'll squash my commits together |
877ef4c
to
ecf287e
Compare
Implement, test and document SIP-42 (Implement is a strong word, I uncommented a single line)
ecf287e
to
5d0be23
Compare
@bishabosha, @sjrd I wasn't sure if I could merge it, so I'll leave you to it |
Reverts #19405 as it was marked as needing minor release.
I noticed we are missing a test for |
Some redundancy was omitted at #19405 https://dotty.epfl.ch/docs/reference/syntax.html
Implement, test and document SIP-42
(Implement is a strong word, I uncommented a single line)