[fpc-pascal] Access Violation When SetLength(DynArray, Value)

Sven Barth pascaldragon at googlemail.com
Sat Sep 10 00:53:37 CEST 2022


Luca Olivetti via fpc-pascal <fpc-pascal at lists.freepascal.org> schrieb am
Fr., 9. Sep. 2022, 15:29:

> I don't know if it is more or less efficient than using a dynamic array
> but I think it's nicer.
>

It internally uses a dynamic array as well, but duplicates the size with
each growth and keeps track of a separate count of elements, thus resulting
in a better performance.

Regards,
Sven

>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20220910/7d2249b7/attachment.htm>


More information about the fpc-pascal mailing list