6 ms·
Looks like Java is slowly but surely catching up to Scala in terms of API, syntactic sugar etc. I wonder if some people disliking Scala compiler slowness would
by msilb 8y ago
Looks like Java is slowly but surely catching up to Scala in terms of API, syntactic sugar etc. I wonder if some people disliking Scala compiler slowness would consider the switch back to Java.
- kod 8y agoMaybe in 15 years Java will finally get pattern matching, but it's never getting higher kinded types.
- carey 8y agoThe first step towards pattern matching will be previewed in JDK 12[1], as a Kotlin-like switch statement, to form the basis of pattern matching[2] together with changes already in JDK 11[3]. I think it will be more like 15 months than 15 years. I don’t expect higher kinded types any time soon, though. [1]: http://openjdk.java.net/jeps/325 http://openjdk.java.net/jeps/325 [2]: http://openjdk.java.net/jeps/305 http://openjdk.java.net/jeps/305 [3]: http://openjdk.java.net/jeps/309 http://openjdk.java.net/jeps/309
- kod 8y agoIf it doesn't have what 305 calls "deconstruction patterns" and "nested patterns", it's not really pattern matching. I'll be impressed if those make it in within 15 months.
- pjmlp 8y agoI only played with Scala but never found a good business reason to actually use it. Personally I rather not be in the bleeding edge and not having to deal with interop issues, or missing tooling.
- pkolaczk 8y agoThe whole point of Scala are its advanced features like implicits, higher kinds and macros, and not just syntactic sugar like in Kotlin. Therefore you won't appreciate Scala by just shortly playing with it. Also in 2018 interop issues or missing tooling problems are long gone.
- pjmlp 8y agoI am well aware of those features. Only Scala shops can make effective use of them, and I am yet to do a project where Scala libraries were even considered.
- pkolaczk 8y agoFar from it. When Java gets pattern matching, Scala will have moved to version 3.0 with trait parameters, union and intersection types, implicit functions, type lambdas, cleaner macros and many more. Also, Scala compiler slowness is virtually not a problem any more since introduction of Zinc 1.0. During development, I get repeatedly compile times around 2-5 seconds on Scala 2.11, and recent Scala 2.12.x / 2.13.x showed to be typically 30%-100% faster than 2.11.x.