Node:FreeMem, Next:function, Previous:FrameAddress, Up:Reference

### FreeMem

#### Synopsis

    procedure FreeMem (var p: Pointer; Size: Cardinal);

or

    procedure FreeMem (var p: Pointer);

#### Description

Releases a chunk of memory previously allocated using `GetMem`. The parameter Size is optional. Its value is currently ignored.

Since Extended Pascal's schemata provide a cleaner way to implement dynamical arrays and such, we recommend using `GetMem` and `FreeMem` only for low-level applications or for interfacing with other languages.

#### Conforming to

`FreeMem` is a Borland Pascal extension. `FreeMem` with only one parameter is a GNU Pascal extension.

#### Example

See GetMem.

#### See also

GetMem, Schema Types, Dispose, Mark, Release.