[fpc-pascal] Type helper for array

Sven Barth pascaldragon at googlemail.com
Fri Jun 10 08:03:47 CEST 2016


Am 10.06.2016 07:36 schrieb "Jürgen Hestermann" <juergen.hestermann at gmx.de>:
>
> Am 2016-06-09 um 20:18 schrieb Sven Barth:
>
> > Am 09.06.2016 17:57 schrieb "Vojtech Cihák" <vojtech.cihak at atlas.cz>:
> > > aBuffer.Clear;
> > > Is it possible to do this without helper?
> >
> > You can always set the array to Nil
>
> IMO SetLength(aBuffer,0) would the most natural way to clear the array.

*shrugs* That's also a way. Bit the question is whether he want to set the
array to empty or if he wants to clear the array's contents without
changing the size.

Regards,
Sven
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20160610/cf935727/attachment.html>


More information about the fpc-pascal mailing list