[fpc-pascal] dynamic array reference count
Xiangrong Fang
xrfang at gmail.com
Sat Mar 15 15:06:09 CET 2014
Hi there,
I just want to confirm one thing:
var
a, b: array of Integer;
begin
SetLength(a, 100);
SetLength(b, 100);
a := b;
end.
Now "a" will point to the same memory block as "b". Since dynamic arrays
are ref counted, I don't need to worry about the memory originally
allocated for "a", right?
Thanks,
Xiangrong
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20140315/4247c5b0/attachment.html>
More information about the fpc-pascal
mailing list