D/Objective-C, extern (Objective-C)
Adam D. Ruppe
destructionator at gmail.com
Mon Jun 24 10:58:48 PDT 2013
On Monday, 24 June 2013 at 17:53:36 UTC, Walter Bright wrote:
> Arc has very serious problems - I don't see how it can be done
> and be memory safe without adding extensive pointer
> annotations. The general problem is someone taking the address
> of a member of the reference counted object. The rc goes to
> zero, the objects gets deleted, and there's that dangling
> pointer to it.
Just thinking out loud, but what if we were able to @disable the
& operator? Then if you needed its address, we could do it with
some other member function that returns a special type that does
the refcount. That'd be a fairly minor language change and would
seal the gap that the library could then fill back in.
More information about the Digitalmars-d-announce
mailing list