implementing copyWithZone:
<pre>
-(id)copyWithZone:(NSZone *)zone
{
MyClass *copy=[[[MyClass alloc] init] autorelease];
...
return copy;
}
</pre>
The Apple developer documentation for copyWithZone: doesn't have the method autorelease the copy, but the documentation states elsewhere that the object responsible for alloc/init'ing an object should be responsible for releasing it. Is there a reason that the copyWithZone: method shouldn't autorelease the copy?
Thanks,
Jim
iMac G4, PowerBook G4