Hi,

On Thu, 19 Jun 2014, mokashe.ram wrote:

> Ok thanks,
>
>    but using untyped pointer how to mention size in GETMEM()?
>
> *      GETMEM(markexam,'' ....");*

It's detailed in the documentation, it's detailed there along with the
rest of the memory management functions, please refer to that:

http://www.freepascal.org/docs-html/rtl/system/getmem.html

So either you use mypointer:=GetMem(size); or GetMem(mypointer, size);
both are valid. If you need to allocate heap space for a record,
use New/Dispose, or GetMem(myptr, sizeof(Tmyrecord));

This changed little since the times of Turbo Pascal, works the same way.

Charlie
_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Reply via email to