On 12/28/14 4:23 AM, Joseph Rushton Wakeling via Digitalmars-d wrote:
On 28/12/14 04:09, Andrei Alexandrescu via Digitalmars-d wrote:
Walter and I have been working on revamping DIP25, which focuses on
tightening
the screws of ref. This should then simplify DIP69 significantly.

Please comment: http://wiki.dlang.org/DIP25

How will that interact with designs like the singleton used in e.g.
std.random.rndGen:

     @property ref Random rndGen() @safe
     {
         import std.algorithm : map, repeat;

         static Random result;
         ...
         return result;
     }

... will it be as simple as adding an 'inout' qualifier to the method
and/or return type?  In any case I think it's a use-case worth adding to
the example list.

No need to add anything here because returning a static is still fine. -- Andrei

Reply via email to