Unofficial wish list status.(Jul 2008)
Walter Bright
newshound1 at digitalmars.com
Tue Jul 22 14:14:32 PDT 2008
superdan wrote:
> yeah and that will be documented in pure vs. impure functions and in
> invariant vs. const/mutable data. this is great. d is not a
> convention-based language like c++.
That is a point worth emphasizing. There are two phases to learning C++:
1. learn the language
2. learn the myriad of conventions that have built up over the years to
ward off all the trouble (Scott Meyer's "Effective C++" series is an
example)
D tries to codify a lot of those conventions into the language, so the
language can actually help you get it right. The const/invariant/pure is
a huge step in that direction. My understanding is that much of peoples'
difficulties with D's const system are the compiler catching attempts to
subvert the const system. These are possible in C++ because const is a
convention, but on the other hand people have terrible problems getting
their multithreaded code to work properly in C++.
Just look at all Herb Sutter's and Scott Meyer's articles on
multithreaded C++ programming where code that looks like it should work
and does compile and work most of the time, but is fundamentally broken.
Language enforcement and guarantees are desperately needed.
> i like messing with cars. i have an
> amazing 18V drill that i use for a ton of stuff - screws, bolts,
> holes, adjustments, rust removal, you name it. does that mean i'm
> only trying to use that tool for everything? sure not. but that
> doesn't make it less loveable.
Me, I've never discovered a problem with my car that couldn't be solved
with a hammer and a torch.
More information about the Digitalmars-d
mailing list