Live data from Hacker News

Announcing Scala.js v0.1

scala-lang.org

31–40 of 90 posts

Re: Announcing Scala.js v0.1

#35

Is there anything Javascript can't do?

Javascript is obviously Turing-complete, so it is as powerful as any other language, and you can implement any other programming language on top of it.

The trick is not wasting too much performance while doing that. Fortunately Javascript performance is already not bad, and specific subsets like asm.js can have their performance optimized even further.

So your question is not unlike "what an x86 command set cannot do?", just for a 50-100x slower command set.

Re: Announcing Scala.js v0.1

#37
post #22

I remember how years ago I complained about how Javascript was the only language aviable for the web. Nowadays you can even run sliced bread on Javascript... though, wouldn't it be better to focus on developing languages on top of asm.js or PNacl so we wouldn't rely on JS?

I completely agree. While asm.js has its problems, its moving in the right direction. Honestly, it seems like this wouldn't be too hard to add a backend target for asm.js, if its implemented well.

Note that asm.js (and probably PNaCL as well) currently offers very little for languages like Scala that need good GC. Until that's addressed simply targeting JavaScript is going to be best approach for these languages.

Re: Announcing Scala.js v0.1

#38

Is there anything Javascript can't do?

Threads.

Not completely true, you already have WebWorkers, and if you're targeting, say, JavaScriptCore on iOS and OS X Mavericks then threads are an option via running multiple JS Virtual Machines - JSValues may be passed between them.

Re: Announcing Scala.js v0.1

#39

Anyone know how the compilation times compare with regular Scala?

Scala's compile times (along with other aspects of its development experience) are among my biggest annoyances with the language. It just seems like it should be way better than it is for such an intellectually advanced language. I've been investing a lot of time in learning Scala because I think that it's at the head of the vanguard of a software engineering revolution, but with some of its ergonomic issues, I can't…

Take a look at Kotlin (http://kotlin.jetbrains.org), it was designed to address the issues you mention.
Post reply on HN