Meaning of allocWithZone:NULL?
Meaning of allocWithZone:NULL?
- Subject: Meaning of allocWithZone:NULL?
- From: Youngjin Kim <email@hidden>
- Date: Wed, 20 Jun 2001 21:24:06 +0900
Hi,
I roughly understand that allocWithZone:[self zone] will use same memory
area with caller object. but what's the meaning of 'allocWithZone:NULL'?
The shared instance of SKTToolPaletteController in Sketch example uses
allocWithZone:NULL, while that of SKToolInspectorController in the same
example uses allocWithZone:[self zone] to create its instance. What's
the difference between two?
SKToolInspectorController implements dealloc method, but is never
actually called. In my understanding, shared instance of both objects
need to be released explicitly. Shouldn't SKTDrawAppDelegate need to
implement applicationWillTerminate method to release memory allocated by
both?
Youngjin