[fpc-pascal] does Advanced Record constructor automatically zero all the memory space of that record?
Dmitry Boyarintsev
skalogryz.lists at gmail.com
Tue Sep 24 12:48:58 CEST 2013
If in doubt, why not to use the old-school records and an
init-value procedure.
thanks,
Dmitry
On Tuesday, September 24, 2013, Dennis Poon wrote:
> **
> if not, is there a clean and easy way to initialize the entire record
> memory space to zeros e.g.
>
> constructor TMyRecord.Create(TheValue : Integer);
> begin
> FillChar(self, sizeof(Self), 0);
> Value := TheVal;
> end;
>
> Is there a Self variable for advanced record methods/constructors ?
>
> By the way, is there an ultimate inherited constructor "Create" for all
> advanced record types?
>
> I cannot find any info by googling, so had to ask for your help here.
>
> Thanks in advanced.
>
>
> Dennis
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20130924/2cfd7473/attachment.html>
More information about the fpc-pascal
mailing list