[fpc-pascal] why dynamic array created in constructor not automatically free in destructor
leledumbo_cool at yahoo.co.id
Thu Aug 7 12:16:22 CEST 2014
> Does this happen too if you declare a dynamic array locally in a function
and leave this function?
The global rule: as soon as the reference count reaches 0, the array gets
unallocated, wherever it's declared and as long as it's accessed normally
without any hack.
View this message in context: http://free-pascal-general.1045716.n5.nabble.com/why-dynamic-array-created-in-constructor-not-automatically-free-in-destructor-tp5719897p5719902.html
Sent from the Free Pascal - General mailing list archive at Nabble.com.
More information about the fpc-pascal