DIP74: Reference Counted Class Objects

bearophile via Digitalmars-d digitalmars-d at puremagic.com
Sun Mar 1 05:13:56 PST 2015


Jacob Carlborg:

> @arc class Foo
> {
>     T1 opAddRef();
>     T2 opRelease();
> }
> ...
> Alternative A gives a clear documentation it's a reference 
> counted class without having to scan the methods.

Assuming you want something like DIP74, this design design seems 
safer than the design proposed in DIP74.

Bye,
bearophile


More information about the Digitalmars-d mailing list