4 ms·
Any reason to use Scala native when Rust exists?
by groceryheist 9y ago
Any reason to use Scala native when Rust exists?
- pacala 9y agoGarbage collection.
- densh 9y agoYou can think of Scala Native as Go on steroids. We don’t try to compete with Rust at all.
- edko 9y agoI am not sure Akka already runs on Scala Native, but if/when it does, that would be my first reason.
- pjmlp 9y agoThe language is more powerful, Rust still doesn't have HKT support. The maturity of the eco-system. Not having to deal with the borrow checker. In any case, I would say in such cases OCaml and Haskell are also good candidates.
- bad_user 9y agoRust is in a different league altogether. Scala, Haskell, OCaml are garbage collected languages. This makes them easier to use, but some problems are out of reach. Embedded development, kernels, native apps requiring performance without frames dropped, real-time systems actually, including consumer stuff like decoding video, these have been the domain of C/C++. Of course, there are projects out there using these languages, pushing the boundaries, like MirageOS (https://mirage.io/ https://mirage.io/) which is built with OCaml. But those are like the exceptions confirming the rule.
- pjmlp 9y agoJava is doing quite well in such domains, including real time control of battleship weapon systems and missile radar controls. The ongoing NLL work proves ergonomics are still not there, and it doesn't cover all scenarios like internal references as done typically for callbacks in GUI widgets. It will surely improve, and the best thing for polyglot developers is that we can easily pick the best tool for the job.
- didibus 9y agoPowerful is a strange choice of word. Did you meant to say more expressive? I feel like if anything, Rust sounds more powerful to me, greater performance, control over memory, low level unsafe access, etc.
- lmm 9y agoHigher-kinded types (worth it for this alone), existing library ecosystem, better tool support, politics. I do hope Rust reaches a stage where it can a substitute for Scala, but without HKT it will never be as productive.
- walkingolof 9y agoThere is plenty of Scala developers that needs to write for example command line tools etc that benefit greatly from the startup times of a native application.