A reason to choose D over Go

cym13 via Digitalmars-d digitalmars-d at puremagic.com
Sun Mar 29 06:05:32 PDT 2015

On Friday, 27 March 2015 at 14:21:18 UTC, Shammah Chancellor 
> D is a superset of go's functionality aside from the structural 
> typing (which in my opinion is a huge fail for a variety of 
> reasons you will see if you try to use it for anything 
> extensive).  If you don't want to learn about templates and 
> metaprogramming, then don't.  I fail to understand why having 
> extra features is a deterrant?
> -Shammah

That's what I thought for a long time, and I still think that it 
is a valid approach, but it should be noted that more features 
makes reading and understanding other's code more difficult.

1/ if you don't know templates, then reading a code making use of 
it needs a long time to identify the construct, read about it, 
understand it and then apply this new knowledge to the original 
piece of code. The identification part is important, how often 
when learning a language did you found a weird syntax that you 
just could'nt identify because it was generic enough not to get 
any useful results in a web search?

2/ more paradigms allow people to write different solutions for a 
same problem. Of course, that's the whole point of accepting 
different paradigms, but it makes it difficult to have a 
uniformed programming style. If you take a language that emphasis 
having one good, elegant, performant way to do things (like 
python) then the code I write will be very similar to the code 
you would have written. Of course there are divergences but there 
is one style that is said to be good and sticking to it means 
that nobody will have problem understanding what I'm writting.

A language that famously took the other path and decided that it 
should allow programmers to solve the same problem in as many 
ways as possible is perl. And if perl is often praised for its 
expressiveness, it is disturbing to see that even perlers are 
often having a hard time deciphering other's code.

More information about the Digitalmars-d mailing list