'. '

Scala

From APIDesign

Revision as of 20:26, 28 May 2009 by JaroslavTulach (Talk | contribs)
Jump to: navigation, search

Scala is a language capable to run on the Java virtual machine. It merges various functional languages concepts with object orietentation quite nicely and cooperates well with existing Java libraries.

Scala Libraries Rant

After being part of the first Scala unconference just after JavaOne 2008 and publishing a recipe how to write NetBeans module extensions in Scala, I had given up on Scala for a longer time.

But as the activity of Artima.com guys is increasing with forthcomming JavaOne 2009, I dediced to give Scala one more try in early May 2009. I think I will be able to like it (as soon as I really learn it more). However I am still far more productive in Java than in Scala, so I rewrote my early May project back to Java.

One reason for that also was my uncertainty. I am still unsure what promises some API construct in Scala mean for BackwardCompatibility. Martin Odersky seems to care more about the language design, than its libraries. Thus it will take time and a lot of trial and error for the other to find out how to write shared libraties that support easy upgradability. Someone will have to document all the evolution gotchas. So far I know I cannot backward compatibly add methods to traits (which sort of beats all their purpose, imho), but there is going to be more, much more hidden catches.

I am not sure how much you like the language, but I, as libraries API designer, feel disgusted looking at core Scala APIs. Have you seen the scaladoc and for example series of Product1, 2, 3, 4, ..., Product13, ... Product20? Why has the so called language of future pollute its core libraries with trash like this? All the beauty one could potentially feel when looking at the language has to be in vain as soon as one see its libraries.

APIs are like stars, you can hardly make them disappear. Does that mean Scala programmers will have to live with this API madness until the end of their days?

--JaroslavTulach 14:52, 28 May 2009 (UTC)

<comments/>

Personal tools
buy