For example:
I have a object created with $object = new stdClass(); it's passed onto a function.
My question is whether the memory allocated for this object is ever freed, if so when does it get freed.
Also how will one check for these changes to memory.
I manually unset($object); right now, just to be safe.