Idea #1 on integrating RC with GC
Adam D. Ruppe
destructionator at gmail.com
Wed Feb 5 13:00:31 PST 2014
On Wednesday, 5 February 2014 at 20:46:32 UTC, Johannes Pfau
wrote:
> However, I wonder if that's really a problem in phobos. I'd
> guess most functions accepting slice input don't store a
> reference.
> We should probably start documenting that. (Or finish 'scope'
> as you already said implicitly ;-).
Aye. If the reference never escapes, it doesn't need to be
counted or freed (indeed, it really MUST never be freed, since
whomever passed you that reference may still be using it and is
responsible for freeing it (or passing the buck to the GC))
More information about the Digitalmars-d
mailing list