Live data from Hacker News

The Road to Scala 3

scala-lang.org

111–120 of 196 posts

Re: The Road to Scala 3

#111
post #75
post #58

The more I read about Scala it makes me wonder why (1) I am not using it (or my team) (2) Java teams across the world are not at least seriously considering changing to Scala. It seems likes it's miles ahead of both Java and even Kotlin.

> Java teams across the world are not at least seriously considering changing to Scala. I've used Scala before. It has challenges that would make it a non-starter for many teams. It has some cool features, but those (IMO) don't outweigh the negatives that come with the language: it's overly complex (different people have very different styles for writing the language), the compiler is slow, it generates more garbage…

What part of Scala 3 do you think is overly complex? From what I understand, it mostly simplifies the language.

Re: The Road to Scala 3

#112
Having recently jumped into a Scala team from a mainly OOP background, I'm starting to see the light with the language. Using the type system to handle code you would otherwise have to write defensively. Letting the compiler take more of the strain of the second order functional concerns of the program and leaving what's left to be an accurate description of your problem domain is a refreshing perspective on coding. Your code looks a lot more like the problem you are trying to solve rather than 75% if(x==null) and 25% business logic. That said, the learning curve is steep and the quasi-hidden nature of implicits never sits well with me. It seems like a way of adding semi-defined behavior to your code and is one of those language features that should be treated with care.

Re: The Road to Scala 3

#113
post #57

I often see comparisons to Go, Kotlin, Rust, etc, and I agree that it's unlikely for Scala to have a second renaissance and have an steep upward trajectory like those languages, but is that really a death of a language? I'm actually fine with Scala narrowing its scope and focus at being really good at just a couple of things. Such as embracing its FP-side more so than its OO-side. Not to say there is no value in its…

What is the story with Scala on Android? Years ago I thought it was a matter of using too much memory. There’s not much talk about it but it does seem to be possible: https://scala-android.org/ Will Scala 3 help?

As the person who was involved in Scala on Android (and particular in creating the website), I'll chime in with this:

What sunk Scala on Android was largely the completely lack of interest from the core team.

Everything that Scala on Android achieved was pretty much _despite_ the actions of Scala's upper echelon.

- It's hard to get a good message out, when core members spread FUD by bringing up problems that were solved year ago (like the big std lib issue).

- The core team's perception of Scala was always inward – new platforms existed such that Scala developers could run their code in more places, not because it could attract new developers from these existing ecosystems to Scala.

(Scala.js partially overcame this by herculean efforts of individual members of the Scala.js community that got the word out to the JavaScript world about Scala.js.)

- Core Scala pulled the plug from Android support in the backend. So Scala on Android was pretty much left to die on an outdated Scala version.

- Something like TASTY (an interchange format that can be recompiled on the fly to target new backends), which could have dealt with the problem above – was promised for years, but still hasn't shipped.

- The core team was against even acknowledging the existence of Scala on Android on the website – good luck in convincing that Scala on Android works, if the official website/documentation doesn't mention it with a single word.

- Core Scala treated the main contributor with so much public disrespect, that I'm still surprised he didn't outright quit back then. It takes balls to publicly blame the main contributor of Scala-on-Android for not working on the project full-time, but also conveniently managing not to tell him this crucial "requirement" for half a decade. And with "full-time" I mean "unpaid full-time".

It's a sad story, because Scala-on-Android shipped with some amazing features like hot-code-replacement years before Google managed to ship it. The typed resources stuff was also pretty impressive.

Re: The Road to Scala 3

#114
post #113
post #57

Earlier quoted context omitted.

What is the story with Scala on Android? Years ago I thought it was a matter of using too much memory. There’s not much talk about it but it does seem to be possible: https://scala-android.org/ Will Scala 3 help?

As the person who was involved in Scala on Android (and particular in creating the website), I'll chime in with this: What sunk Scala on Android was largely the completely lack of interest from the core team. Everything that Scala on Android achieved was pretty much _despite_ the actions of Scala's upper echelon. - It's hard to get a good message out, when core members spread FUD by bringing up problems that were sol…

So, no, Scala 3 won't help. Most people who cared left years ago.

Re: The Road to Scala 3

#115

Earlier quoted context omitted.

Interested but how much as good as with kotlin? Being compatible is one thing, being as idiomatic is another.

Nowhere near as good or as seamless as Kotlin interop, Kotlin made interop a priority/first class feature. When using a Java library in Clojure, many times its just better to just write some Java for your Clojure program specifically for the purpose of calling it from Clojure.

> When using a Java library in Clojure, many times its just better to just write some Java for your Clojure program specifically for the purpose of calling it from Clojure.

What? Calling Java from Clojure couldn't be any easier. The same as calling JavasScript from ClojureScript

Re: The Road to Scala 3

#116
post #41

Earlier quoted context omitted.

This is all marketing. I've never found a more sophisticated type system anything but helpful. It's easy for beginners to start, but when you don't have a good type system and you have a complicated project things quickly become a nightmare.

eh, there is still a cost to it, don't get me wrong I generally think generics are worth the cost if done right, but they can also go really wrong

When?

Re: The Road to Scala 3

#117
post #111
post #75

Earlier quoted context omitted.

> Java teams across the world are not at least seriously considering changing to Scala. I've used Scala before. It has challenges that would make it a non-starter for many teams. It has some cool features, but those (IMO) don't outweigh the negatives that come with the language: it's overly complex (different people have very different styles for writing the language), the compiler is slow, it generates more garbage…

What part of Scala 3 do you think is overly complex? From what I understand, it mostly simplifies the language.

It absolutely does not.

It removes a few things and adds a whole lot of new stuff to it.

It's a bigger, more complex language, even if you credit all the cleanups that were already in Scala 2 to Scala 3.

Re: The Road to Scala 3

#118
post #39

I see a lot of people complaining about Scala. I looked into it 9 years ago but it didn’t seem to be gaining traction so I stopped playing with it: https://github.com/melling/scala Recently, however, I’ve noticed that Scala does to be be quite alive (3.0, ScalaDays, Cats, Shapeless, Scala.js) so I’m taking another crack at it. I’ve done a lot in Swift and it’s my current favorite language, but it’s not widely support…

Swift seems to have taken a number of its early ideas from Scala, particularly around some of its functional concepts.

Re: The Road to Scala 3

#119

Earlier quoted context omitted.

That's a complete myth, really. The Scala ecosystem has its fair share of problems, but Odersky and his lab's involvement and stewardship have never been one of them.

Just an example: Why wasn't it a priority to make scala run well on dalvik? The place is taken by kotlin and is one of its strongest selling points.

Core team didn't care about Android. Simple as that. :-)

Re: The Road to Scala 3

#120

Earlier quoted context omitted.

eh, there is still a cost to it, don't get me wrong I generally think generics are worth the cost if done right, but they can also go really wrong

When?

Scalas insane generic type system would be an example of them going wrong. The current proposed Go method seems fairly reasonable.
Post reply on HN