Just where has this language gone wrong?

Timon Gehr timon.gehr at gmx.ch
Thu Jul 19 08:14:42 PDT 2012


On 07/19/2012 05:03 PM, Petr Janda wrote:
>> It's just syntax. Eliminating syntax noise is fine. Code should look
>> like what it does.
>
> Not if "eliminating noise" equals to making things harder to understand.
>

Harder to understand to whom? Optimizing stuff for beginners usually
makes it a PITA to work with.

> When you say (int x) { return x; } it's clear about what it is, a
> _function_ without name.

That expression looks eg. like this in Haskell:
\x->x

(If the type of x cannot be inferred to Int, then it is (\x->x)::Int->Int)

I agree that there is some non-uniformity. It should be possible to use
=> in named function declarations.



More information about the Digitalmars-d mailing list