Hacker News new | ask | show | jobs
by bad_user 4628 days ago
I have been using Scala for both server-side and Android projects. Android doesn't have such a capable VM and Scala is a little wasteful in terms of short-term objects, but using Scala while being mindful about performance implications of the code you write is still better than Java. In fact on Android you can use pretty much any language under the sun, including languages that don't run on top of the JVM. The development experience may not be as great as when using Java, sometimes you suffer from interoperability issues and so on, but for personal projects it's OK.

iOS doesn't force you to use Objective-C either. For example many top games or apps have been built in C#, by means of Unity or MonoTouch. The problem with iOS is Apple's developer agreement, as they first didn't allow apps written in anything else than Obj-C, after which they changed that to not allowing apps doing JIT compilation, but now they only enforce this rule when banning apps that download and execute code on the fly. For this reason, when embedding a WebView inside an app, Javascript will not have the same performance as Safari's Javascript engine, which is kind of stupid. So many devs prefer native compilation to avoid any problems. There's nothing wrong with iOS as a platform, what's wrong is with Apple's restrictive policies.

1 comments

> The development experience may not be as great as when using Java

Exactly. I'm pretty sure that switching to something like Scala wouldn't improve my productivity.

We've got a parable in our country about a lazy bastard, that couldn't do anything out of laziness to the point of dying from hunger. One day a woman offers to help him, to give him shelter and food. To which the lazy man asks in response ... will you soak my bread? (sounds much better in Romanian)

Fuck dude. You're a developer. If you want productivity, make shit happen.

wtf?
I think that they are saying that Scala is the proverbial bread being offered to you, and your concerns about productivity are akin to insisting that your bread be soaked so that it's easy to eat.

If that is what they're saying, I disagree with them.