On 16/11/11 1:19 AM, Andrei Alexandrescu wrote:
On 11/15/11 11:51 AM, Peter Alexander wrote:
I just feel like that page is desperately trying to sell D, rather than
just humbly introducing it and letting the language speak for itself.
I don't think "letting the language speak for itself" works. People who
are willing to get to that point are already interested. The challenge
is having someone with only a fleeting curiosity get a quick overview of
why they should become interested. We want to send a clear and crisp
message about D. This is not about being humble vs. arrogant or whatnot.
By "letting the language speak for itself" I mean that we shouldn't
resort to desperate sales pitches:
"Concurrency seems difficult? Fear no more." <-- cheesy sales pitch
"True immutable data, no sharing by default, and controlled mutable
sharing across threads." <-- letting the language speak
From your message I distinguish eight keyphrases:
- statically typed
- natively compiled
- type deduction
- automatic memory management
- C-family syntax
- pragmatism
- safety
- powerful abstractions
These are accurate, but eight is a lot of'em. How would you compress
them in three powerful messages?
Why do we need three powerful messages? No other language website does
that and I don't see why we should do it.
Short introduction (like the one I already posted) + tiny code sample.
import std.stdio;
void main()
{
// 'line' statically deduced to string type
foreach (line; File("text.txt").byLine())
writeln(line);
}
That tiny code sample demonstrates:
- C-family syntax
- Static typing
- Type deduction
- Automatic memory management
- Powerful abstractions
The missing things could easily be stated in any short paragraph.