null references redux + Looney Tunes

language_fan somewhere at internet.com.invalid
Sun Oct 4 03:11:19 PDT 2009


On Sun, 04 Oct 2009 11:51:13 +0200, Lutger wrote:

> How do you think Scala is going to manage to be a popular alternative
> for Java by requiring its user to read books about lambda calculus?

It's not necessary. Often removing extra semicolons and changing the form 
'<type> <value>' to '<value> : <type>' suffices. Especially when porting 
Java code.

> The keyword metric is so flawed you just cannot base any argument around
> it.

I admitted that later. Some of the keywords have a strong justification 
behind them. Others feel irritatingly unnecessary.

Imagine if D had keywords goto_unknown, goto_forward and goto_backward, 
and goto_here (which is rewritten as while(true) {} by the compiler), 
based on how the program counter will change. Jumps to addresses with a 
lower program counter value use goto_backward, vice versa for 
goto_forward. Situations where the pc value is runtime determined would 
have to use goto_unknown. D 2.0 would also have construct 'goto dynamic
(addr);' which would behave identically to 'goto_unknown addr;'. Now some 
of you might see a pattern here and would try to combine the various 
gotos into a single keyword. I am talking about similar situation, but my 
focus is on a higher level.

> I highly recommend this short and subjective article on the subject by
> Yukihiro Matsumoto: "Treating Code as an Essay" from the book Beautiful
> Code. Unfortunately I couldn't find it online.

Thanks. Added to my todo list.



More information about the Digitalmars-d mailing list