www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - Copy-on-Write wrapper of std.typecons.RefCounted

reply Per =?UTF-8?B?Tm9yZGzDtnc=?= <per.nordlow gmail.com> writes:
Has anybody been able to partially or completely extend 
`std.typecons.RefCounted(T)` to transparently do copy-on-write 
(CoW) when calling non-const members of `T`?
Oct 25
parent Per =?UTF-8?B?Tm9yZGzDtnc=?= <per.nordlow gmail.com> writes:
On Friday, 25 October 2024 at 18:19:27 UTC, Per Nordlöw wrote:
 Has anybody been able to partially or completely extend 
 `std.typecons.RefCounted(T)` to transparently do copy-on-write 
 (CoW) when calling non-const members of `T`?
I think the key enabler is opDispatch.
Oct 25