The Java virtual machine has become a popular destination for programming languages other than Java itself. Three of those languages -- Frege, Kotlin, and Mirah -- squared off at the JavaOne conference this week, with each ready to reach new milestones in their development.
Frege, voted most popular language among attendees in the conference session, is a Haskell variant. The language scored a GitHub rating of 1,392 stars and is useful in cloud application development, said project committer Dierk Konig, director of engineering at Canoo Engineering. “The cloud story of Frege is really, Frege takes Haskell code and compiles it to Java [source code].” Therefore, the cloud story for Frege is exactly the same as Java, he said. Frege offers functional programming, a strong static type system, and global type inference. It can use any Java library.
“The next release will focus on getting all those little deviations from Haskell ironed out so that we are as close as possible to Haskell,” Konig said in an interview after the session. That release, version 3.24, is due soon. He explained there have been some deviations from the Haskell syntax that will be fixed.
Mirah, which had been headed by JRuby developer Charles Nutter, is now the pet project of maintainer Nick Howard, a senior software engineer at Twitter. The language has been billed as bringing Ruby capabilities to Java. It is a static language that uses Ruby syntax but has no runtime JARs. “If you understand Java and you’re familiar with Ruby, you might like Mirah,” Howard said. The language was rating 766 stars on GitHub and finished second in the JavaOne session polling.
Mirah is sort of a Java substitute and can take advantage of existing tools. “It’s compiling the same kind of byte code that Java does,” Howard said. Additionally, a tool called Pindah can write Android applications in Mirah. The next Mirah release, vesion 0.1.5, is due out within days and will feature a faster compiler. A planned 1.0 release may add generics, extension methods, and gradual typing.
Kotlin, which recently issued a 1.0 beta candidate release, is a JetBrains project, registering 2,213 GitHub stars but finishing third in the conference session polling. It is a statically typed language for the JVM that also supports Android development and writing of domain-specific languages. “Because it’s completely compatible with Java 6 and 7, you can run it on Android,” said Hadi Hariri, team lead at JetBrains. A 1.0 release is planned by the end of the year.
This story, "Which code is best? 3 JVM languages duke it out" was originally published by InfoWorld.