const/immutable member functions

foobar foo at bar.com
Mon Jan 24 15:44:04 PST 2011


bearophile Wrote:

> foobar:
> 
> > This "problem" happens because D belongs to the C-family of languages which puts the return type _before_ the function name.
> 
> Of course C++ has everything :-) See the trailing-return-type feature of C++0x:
> http://en.wikipedia.org/wiki/C%2B%2B0x#Alternative_function_syntax
> http://stackoverflow.com/questions/4523617/omit-return-type-in-c0x
> 
> Bye,
> bearophile

Of course they added it, they also experienced similar problems with the current syntax since it is out of place in the reading order. 


More information about the Digitalmars-d mailing list