`return const` parameters make `inout` obsolete

via Digitalmars-d digitalmars-d at puremagic.com
Mon Mar 16 09:17:04 PDT 2015

On Monday, 16 March 2015 at 16:02:57 UTC, Idan Arye wrote:
> On Monday, 16 March 2015 at 14:17:58 UTC, Zach the Mystic wrote:
>> char* fun(return const char* x);
>> Compiler has enough information to adjust the return type of 
>> `fun()` to that of input `x`. This assumes return parameters 
>> have been generalized to all reference types. Destroy.
> Is the `return` in the argument list a new feature? It doesn't 
> compile in 2.066, and I don't see it in 2.067's changelog...

It's been experimentally introduced by DIP25:

More information about the Digitalmars-d mailing list