4 ms·
Also, Scala is not "built on" the Java language, as far as I know. It compiles to bytecode, just as the Java language does.
by vetler 15y ago
Also, Scala is not "built on" the Java language, as far as I know. It compiles to bytecode, just as the Java language does.
- gaius 15y agoYep, at this point in history Java-the-language and Java-the-VM are related in name only.
- thomaslangston 15y agoCould you elaborate? It is my understanding that 99.9% of Java syntax is valid Scala syntax. How does that correlate with your statement?
- JoachimSchipper 15y agoThe compilation path is Scala -> JVM bytecode [-> x86 assembly], not Scala -> Java -> JVM bytecode [-> x86 assembly]. At least, that's what I think your parent comment was saying.
- msmith 15y agoNo, Java and Scala syntax are quite different. I can really only think of a few cases where they share syntax.
- ominous_prime 15y agoI wonder where people are getting this (you're not the first person I've heard this from)? The syntax is not compatible at all. You can write programs in the same style, e.g. object oriented with inheritance, global state, side effects, and so on; but the similarity ends there.
- eevilspock 15y agoAgreed. Likewise the article is wrong when it says Java is built "on top" of C/C++. It compiles to JVM bytecode which is JIT compiled to native machine code. So its whole "thinking logically" premise is broken.