Rust and D

Peter Alexander peter.alexander.au at gmail.com
Sat Sep 29 05:05:19 PDT 2012


On Saturday, 29 September 2012 at 11:18:40 UTC, Paulo Pinto wrote:
> On Saturday, 29 September 2012 at 10:53:57 UTC, Peter Alexander
>> My question to you: Is it okay to reject D solely with these 
>> arguments? If not, how is this any different from rejecting Go 
>> solely from its lack of generics?
>
> Because except for Go, all static languages developed after 
> 1990, which managed to gain mainstream use, have some form of 
> generics.

There's two ways to interpret this sentence:

1. You claim it is okay to reject Go because it differs from 
other statically typed languages, or
2. You claim that all statically typed languages must have 
generics to be worth using.

I hope it is not 1, and if it is 2 then again, I find this 
incredibly unimaginative.

Interestingly, Rob Pike comments on this world view:

http://commandcenter.blogspot.co.uk/2012/06/less-is-exponentially-more.html
----
"Early in the rollout of Go I was told by someone that he could 
not imagine working in a language without generic types. As I 
have reported elsewhere, I found that an odd remark.

To be fair he was probably saying in his own way that he really 
liked what the STL does for him in C++. For the purpose of 
argument, though, let's take his claim at face value.

What it says is that he finds writing containers like lists of 
ints and maps of strings an unbearable burden. I find that an odd 
claim. I spend very little of my programming time struggling with 
those issues, even in languages without generic types.

But more important, what it says is that types are the way to 
lift that burden. Types. Not polymorphic functions or language 
primitives or helpers of other kinds, but types.

That's the detail that sticks with me."
----


More information about the Digitalmars-d mailing list