FreeStructure and arrays?
-
- New User
- Posts: 8
- Joined: Wed Jul 19, 2017 5:50 am
FreeStructure and arrays?
I have a structure that has a field that is an array. When I call FreeStructure to remove it from memory, does the array get freed and deleted nicely or do I have to call FreeArray first?
Re: FreeStructure and arrays?
FreeStructure() is "smart" and will free Arrays, Lists, Maps, assuming you allocated it with AllocateStructure().
FreeMemory() is naive and does NOT free these member objects.
(Just like AllocateMemory() does not initialize them.)
FreeMemory() is naive and does NOT free these member objects.
(Just like AllocateMemory() does not initialize them.)