Hi,
How does the garbage collector react to live threads in which there are no
references to it?
For example,
myclass {
NSThread *mythread;
}
mythread = [[NSThread alloc] initWith];
[mythread start];
...
//mythread is still running its main method
mythread = nil;
Would mythread be considered
On Sep 14, 2009, at 11:54 AM, Edward Chan wrote:
Would mythread be considered garbage and be collected even though it
hasn't
finished running? If so, would it be cancelled first? Or would it
just get
killed?
Threads aren't garbage collected; they're implemented at a lower
level. (Or
thanks!
On Mon, Sep 14, 2009 at 3:26 PM, Jens Alfke j...@mooseyard.com wrote:
On Sep 14, 2009, at 11:54 AM, Edward Chan wrote:
Would mythread be considered garbage and be collected even though it
hasn't
finished running? If so, would it be cancelled first? Or would it just get
killed?