On Sunday, 21 February 2016 at 15:03:39 UTC, Marc Schütz wrote:
I've adapted my previous DIP on lazy initialization to make it
usable for logical immutability, as is useful for reference
counting, among other things:
http://wiki.dlang.org/DIP89
BTW the Usage section still uses lazy. I think the RCObject code
shouldn't use new to construct the struct here:
auto o = new immutable(RCObject);
It probably needs to be on the stack instead.
(I also made a minor edit for formatting/readability, hope that's
OK).