const/immutable member functions

foobar foo at bar.com
Tue Jan 25 13:07:49 PST 2011


so Wrote:

> > C++ is indeed complex and one of the reasons is its syntax (believe it  
> > or not). There was even an academic project to re-syntax C++ with the  
> > exact same semantics.
> > Of course it's not the only cause of complexity in C++ but it is  
> > definitely one of the main ones.
> 
> If that is the case, you are probably right, but still i can't quite grasp  
> it.
> 
> > C++'s complexity has nothing to do with it's "power". D is as powerful  
> > and is less complex to use which is why we are here and not on the C++  
> > dev mailing list. for example, D's classes/structs are way better than  
> > equivalent c++ code.
> 
> Well if you think the complexity has nothing to do with power, how can you  
> use D as a counterexample? :)

"power" is a very subjective and problematic measure. We're discussing Turing complete languages and nothing prevents me from implementing a compiler/interpreter from one language to another thus gaining its "power". 
What we really want to talk is ease of expressiveness.
C++ is more complex than D which means its harder to express oneself in c++. The difference is not that you can express something in one language but not in another (Both are Turing complete) but rather the *difficulty* of expressing the same thing in both languages.

That difficulty makes for a steeper learning curve. 


More information about the Digitalmars-d mailing list