On 12/29/14 2:04 PM, Dicebot wrote:
On Monday, 29 December 2014 at 19:00:06 UTC, Andrei Alexandrescu wrote:
I tend to agree. You seem to have shown that reusing inout for scope
information becomes confusing. -- Andrei

What is the problem with using inout exactly as it is now (== both for
argument and return type) but defining it to propagate aliasing
information as it is decribed in DIP25?

It can, and I don't have a problem for that.

But I think disallowing:

ref T foo(T)(ref T t) { return t;}

Is no good. The DIP seems to be indicating inout can have another use that has nothing to do with const, but I'm not exactly sure.

Ironically, inout used to be an alias for ref :)

-Steve

Reply via email to