Java > Scala

Walter Bright newshound2 at digitalmars.com
Wed Nov 30 00:48:52 PST 2011


On 11/30/2011 12:29 AM, Russel Winder wrote:
> Walter,
>
> On Wed, 2011-11-30 at 00:17 -0800, Walter Bright wrote:
>> On 11/29/2011 11:42 PM, Jacob Carlborg wrote:
>>> I think it has something to do with Scala trying to be compatible with Java.
>>
>> It has to run on the JVM, which is a large and heavy rock.
>
> I think only response possible to this is "bollocks".
>
> It may be what you believe, but that doesn't make it true as an abstract
> statement.

I used to be intimately familiar with the JVM, I even wrote a gc for it. The 
bytecode ops in it are designed for Java, nothing more. Worse, it's a primitive 
stack machine. To generate even passably good native code, the JVM has to do a 
lot of reverse engineering of the bytecode.

For example, you cannot pass by value anything other than the primitive Java 
data types. There are no pointers. Want an unsigned int? Forget it. Arrays of 
anything but class references? Nyuk nyuk nyuk. Etc.



More information about the Digitalmars-d mailing list