3 ms·
I wish they had gone with Groovy. Groovy 2.x offers pretty much all the benefits of static compilation and dynamic language features together, it compiles on t
by zmmmmm 14y ago
I wish they had gone with Groovy. Groovy 2.x offers pretty much all the benefits of static compilation and dynamic language features together, it compiles on the fly instantly (being at its heart a dynamic language), and has meta programming features (intercepting it's own compilation and changing the AST, etc.) that would rival Scala's.
There's a project out there somewhere for integrating Groovy with Play but it looks quite immature.
- vorg 14y ago> I wish they had gone with Groovy. Play 2 stripped out all the Groovy code from Play 1. There must be a reason. > Groovy 2.x offers pretty much all the benefits of static compilation and dynamic language features together Groovy's dynamic compilation is reliable, but sloooooooooow. The static compilation added in Groovy 2 is much faster but still buggy e.g. http://stackoverflow.com/questions/14774709/groovy-2-1-0-weird-behaviour-of-switch-case-break-statement-with-compilestatic http://stackoverflow.com/questions/14774709/groovy-2-1-0-wei... It was written by one developer, and first shipped in Grails only 2 months ago. And does Grails actually use any of Groovy's static compilation features? I haven't seen anywhere it's used: point me to somewhere in the Grails codebase if it does. You don't get all the benefits of static compilation and dynamic compilation together, you can get bugfree (but sloooooooooow) code, or faster (but buggy) code.
- zmmmmm 14y ago> Groovy's dynamic compilation is reliable, but sloooooooooow. I guess you mean execution speed, not compilation? Compilation is fast enough I think. Execution certainly compares fine with other dynamic languages, at least, in my usage (and for some things it is much faster). > The static compilation added in Groovy 2 is much faster but still buggy The bug you mention is certainly bad, but it was addressed extremely quickly. Are there other examples? > It was written by one developer, and first shipped in Grails only 2 months ago A little misleading - static compilation has been in core Groovy for 9 months or so and is now supported by the core groovy team. > And does Grails actually use any of Groovy's static compilation features? I don't know, but it's not really relevant. I'm not advocating for Grails here, I'm advocating use of Groovy with Play. Part of the reason I want that is that I'm not extremely fond of Grails for various reasons.
- nnq 14y agoWhen Groovy's author said he prefers Scala (http://macstrac.blogspot.ro/2009/04/scala-as-long-term-replacement-for.html http://macstrac.blogspot.ro/2009/04/scala-as-long-term-repla...) it pretty much sealed the language's fate... though, in all seriousness, there really is too much language diversity on the JVM (how tf would one choose between Groovy, JRuby or JPython? - yeah, you choose the framework not the language, but still, it means that all the good developers are split working on different projects).
- don_draper 14y agoThat statement is misleading. James Strachan left Groovy a long time ago. Guillaume Laforge has lead the project from almost death to one of the most popular languages in use today.
- vorg 14y agoMost of the technical work has been done by Jochen Theodorou. Others who have helped technically are Paul King, Cedric Champeau, Alex Tkachman, and Jeremy Rayner. James Strachan also did a lot of technical work on Groovy in his day. I'd rather listen to what someone who's done technical work has to say than someone who shows powerpoint slides. You mentioned Guillaume Laforge as leading the Groovy project, but from my experience, Graeme Rocher, the Grails Project Manager, seems to have far more say over Groovy's direction. As for calling Groovy "one of the most popular languages in use today", it figures fairly low in most popularity ratings (e.g. not in Tiobe's top 50), and only shows the occasional burst when it's been actively talked up, e.g. just before a conference when the project managers are selling conference seats.
- zmmmmm 14y agoThat piece is very dated, and your comment is misleading. He didn't consider Groovy as a replacement for Java at the time because it was not statically typed and did not compile to fast byte code. In fact, if you read through all the reasons he recommends Scala, every one of them has been addressed in Groovy in the last few years.
- 14y ago