News for hackers. Stuff that matters.
Re:“No, we’re telling everyone we are using Java” by zmmmmm on Saturday March 09, 2019 @02:45PM (#19348046)
I still tell people we're using Java instead of Groovy, but that's more because I can't be bothered having the repeated 5 minute discussion with them about what it is. (Besides that, I actually consider Groovy almost to be essentially like a template engine or set of macros for writing Java code. It's not like other JVM languages that try to introduce a different style).
Re:“No, we’re telling everyone we are using Java” by linkmotif on Saturday March 09, 2019 @02:53PM (#19348104)
Groovy, the real JavaScript. I love Spock but never could get into using Groovy for non-test code.
Re:“No, we’re telling everyone we are using Java” by vorg on Saturday March 09, 2019 @05:30PM (#19348942)
Good idea. I refer to Apache Groovy as "Bash for the JVM". The static typing features in Groovy were bolted on for version 2, whereas Scala and Kotlin were designed from the ground up for building actual systems on the JVM, so they're a far better choice for that.
Re:“No, we’re telling everyone we are using Java” by zmmmmm on Saturday March 09, 2019 @04:33PM (#19348626)
Yeah, you really need to adopt a completely different style if you're writing a whole applications with Groovy as opposed to scripting or test code. It's like a different language almost (more like nicer Java). It does work quite well for it when you do that though.
Re:“No, we’re telling everyone we are using Java” by linkmotif on Saturday March 09, 2019 @05:59PM (#19349091)
I really like groovy with all its groovy idioms and its extended library. It’s really fun to Google for how to write something in Groovy you usually get something really ice. I just didn’t like the lack of typing for non test code. And spotty IDE support even in IntelliJ. It seems to be perfect for tests because your code still compiles and you can fix the tests when you’re ready. Also Spock is beautiful...
Re:“No, we’re telling everyone we are using Java” by nitrogen on Saturday March 09, 2019 @02:56PM (#19348115)
You might enjoy Kotlin.
Re:“No, we’re telling everyone we are using Java” by linkmotif on Saturday March 09, 2019 @03:13PM (#19348206)
Yeah I really want to move to a language with pattern matching. Hopefully it will finally land in Java
Re:“No, we’re telling everyone we are using Java” by vbezhenar on Saturday March 09, 2019 @04:46PM (#19348699)
Kotlin does not support pattern matching.
Re:“No, we’re telling everyone we are using Java” by sk5t on Saturday March 09, 2019 @05:36PM (#19348973)
Yeah, Kotlin has some "enhanced switch" type stuff, but nothing that compares to Scala's matching with unapply, list extraction, etc.
Re:“No, we’re telling everyone we are using Java” by vbezhenar on Sunday March 10, 2019 @06:19AM (#19351296)
Actually they have some foundations, componentN functions serve similar role to unapply, so theoretically it should be possible to build good enough pattern matching. But, unfortunately, they seem to slow down language development a lot since release.
Re:“No, we’re telling everyone we are using Java” by nostrademons on Saturday March 09, 2019 @06:46PM (#19349294)
It has destructuring in value binding and lambda parameters, as well. Pretty handy when you're dealing with a lot of pairs, triples, and data classes, though not quite as powerful as true pattern-matching.
Re:“No, we’re telling everyone we are using Java” by linkmotif on Saturday March 09, 2019 @05:57PM (#19349076)
Oh! Thought it did. Forget Kotlin, then :)!!
Re:“No, we’re telling everyone we are using Java” by sk5t on Saturday March 09, 2019 @06:04PM (#19349114)
Kotlin is still a pleasant language to use, and some of the ideas have some good carryover to Scala, with quite a lot less culture shock than going right from Java to Scala.
Re:“No, we’re telling everyone we are using Java” by dionian on Saturday March 09, 2019 @06:01PM (#19349100)
scala, eta
Re:“No, we’re telling everyone we are using Java” by Floegipoky on Saturday March 09, 2019 @11:35PM (#19350285)