-[NSAppleEventDescriptor initWithAEDescNoCopy] memory management question
-[NSAppleEventDescriptor initWithAEDescNoCopy] memory management question
- Subject: -[NSAppleEventDescriptor initWithAEDescNoCopy] memory management question
- From: Jim Correia <email@hidden>
- Date: Thu, 7 Apr 2005 18:09:12 -0400
The documentation says:
initWithAEDescNoCopy:
- (id)initWithAEDescNoCopy:(const AEDesc *)aeDesc
Initializes and returns an NSAppleEventDescriptor that takes ownership
of the Carbon AEDesc structure pointed to by aeDesc. Returns nil if an
error occurs. The initialized object takes responsibility for calling
the AEDisposeDesc function on the AEDesc at object deallocation time.
This is the designated initializer for this class.
So it is clear that NSAppleEventDescriptor will call AEDisposeDesc on
my behalf.
What about the storage for the AEDesc itself? Does it call free? Does
it assume the storage will live longer than the object, and I am
responsible?
Thanks,
Jim
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden