-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Deprecate unicode arrows ⇒, ← and →
#7540
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
Conversation
fd7d343 to
9dd13d8
Compare
|
More like 💘 an arrow through the heart. |
|
I could only rely on the formatter to help me input these arrows. |
|
Will we ever get the arrows back as operator characters? Page one of the spec should clarify. |
|
I'm in favor, because of the precedence considerations (scala/bug#11210). also more generally it just seems better to me to not go the Unicode-symbol path at all, rather than maybe have it piecemeal here and there for a few things any other @scala/committers opinions? |
dwijnand
left a comment
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.
LGTM
|
I agree scala/bug#11210 is a good reason to deprecate unicode arrows but want to note that unicode arrows are widely used (it was a heavily requested Scalafmt feature). Scalafmt supports rewriting unicode to ascii and vice-versa. If unicode arrows are deprecated in the language we will likely remove the option to go to unicode and by default rewrite unicode into ascii. |
|
Yeah, I think we should discuss more widely. I’ve also seen this in the
Akka code base quite a bit.
…On Thu, 10 Jan 2019 at 11:49, Ólafur Páll Geirsson ***@***.***> wrote:
I agree scala/bug#11210 <scala/bug#11210> is a
good reason to deprecate unicode arrows but want to note that unicode
arrows are widely used (it was a heavily requested Scalafmt feature).
Scalafmt supports rewriting unicode to ascii and vice-versa. If unicode
arrows are deprecated in the language we will likely remove the option to
go to unicode and by default rewrite unicode into ascii.
—
You are receiving this because you are on a team that was mentioned.
Reply to this email directly, view it on GitHub
<#7540 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAFjy-Y_oy8VU0MLM9b_CBm3hmkMODXZks5vBxqvgaJpZM4ZU6Ic>
.
|
|
The Akka Team's fine with losing them. 🙂 |
|
I've always thought they were kinda cute, and generally harmless. The precedence bug puts the lie to harmlessness, though, so I'm okay with dropping them and relying on my fancy ligature font. |
|
I'm in favour of removing them |
|
Also in favor of removing them, use font-ligatures (which are now very widely supported in basically every editor) if you want these symbols |
9dd13d8 to
88546d7
Compare
|
Rebasing and merging since there appears to be consensus. |
I think that could happen at the time of actual removal |
* Remove Unicode arrows (deprecated in Scala 2.13) Reference: scala/scala#7540 * Linter: Fix unused config parameter SuperSafe: Remove usage of .equals Scalafix: remove unused imports & private hex function There is no need to guard against LHS null in Scala equality and isInstanceOf * Remove some hidden typos * Bump legacy Scala to 2.12.8 * Enable TLS security in README, bump shields to Scala 2.13
- final case classes - no return() statements - use ASCII arrows instead of unicode arrows `⇒`, `←` and `→` - avoid '+' for string concatenation ref: Scala best practices https://nrinaudo.github.io/talk-scala-best-practices/#72 Issue #14 #14 ASCII arrows scala/scala#7540
|
IntelliJ IDEA now ships with JetBrains Mono, a programming font with great ligature support for constructs used in Scala code. It will be the default font in the upcoming IDE release. https://www.jetbrains.com/lp/mono/ |
As of Scala 2.13, Unicode arrows are deprecated: * scala/scala#7540 * scala/scala-dev#585 * scala/bug#11210 Using one will give a deprecation warnings like so: > The unicode arrow `⇒` is deprecated, use `=>` instead. If you still wish to > display it as one character, consider using a font with programming ligatures > such as Fira Code. As such the Scala layer's version slick capability to replace ASCII arrows with Unicode ones is no longer useful, and I have removed it. Based on my tests it doesn't seem that there is a need for a more graceful way to deprecate this: i.e. nothing fails if there is extra junk in `:variables`.
As of Scala 2.13, Unicode arrows are deprecated: * scala/scala#7540 * scala/scala-dev#585 * scala/bug#11210 Using one will give a deprecation warnings like so: > The unicode arrow `⇒` is deprecated, use `=>` instead. If you still wish to > display it as one character, consider using a font with programming ligatures > such as Fira Code. As such the Scala layer's version slick capability to replace ASCII arrows with Unicode ones is no longer useful, and I have removed it. Based on my tests it doesn't seem that there is a need for a more graceful way to deprecate this: i.e. nothing fails if there is extra junk in `:variables`.
As of Scala 2.13, Unicode arrows are deprecated: * scala/scala#7540 * scala/scala-dev#585 * scala/bug#11210 Using one will give a deprecation warnings like so: > The unicode arrow `⇒` is deprecated, use `=>` instead. If you still wish to > display it as one character, consider using a font with programming ligatures > such as Fira Code. As such the Scala layer's version slick capability to replace ASCII arrows with Unicode ones is no longer useful, and I have removed it. Based on my tests it doesn't seem that there is a need for a more graceful way to deprecate this: i.e. nothing fails if there is extra junk in `:variables`.
As of Scala 2.13, Unicode arrows are deprecated: * scala/scala#7540 * scala/scala-dev#585 * scala/bug#11210 Using one will give a deprecation warnings like so: > The unicode arrow `⇒` is deprecated, use `=>` instead. If you still wish to > display it as one character, consider using a font with programming ligatures > such as Fira Code. As such the Scala layer's version slick capability to replace ASCII arrows with Unicode ones is no longer useful, and I have removed it. Based on my tests it doesn't seem that there is a need for a more graceful way to deprecate this: i.e. nothing fails if there is extra junk in `:variables`.
Unicode arrows are deprecated in Scala 2.13, thanks to scala/scala#7540 merged in January 2019. For consistency, unless there's been a conscious decision to _un_deprecate them, we should continue that on into Scala 3.
Unicode arrows are deprecated in Scala 2.13, thanks to scala/scala#7540 merged in January 2019. For consistency, unless there's been a conscious decision to _un_deprecate them, we should continue that on into Scala 3.
Fixes scala/scala-dev#585
Fixes scala/bug#11210