[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GNUstep and valgrind

From: Richard Frith-Macdonald
Subject: Re: GNUstep and valgrind
Date: Fri, 16 Mar 2018 18:11:06 +0000

> On 16 Mar 2018, at 17:58, Fred Kiefer <address@hidden> wrote:
> I think that now I see the flaw in my argument. I was under the impression 
> that an autorelease pool will only release contained objects if they have a 
> reference count of one. But that is nonsense. The autorelease pool will 
> release all contained objects and as usual the ones where the reference count 
> drops to zero will be deallocated. The autorelease pool itself doesn’t care 
> about the reference count. That way your example was correct, with the 
> autorelease pool around the object creation they will only be retained by the 
> array and go away when that is deallocated.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]