16.13 The HEAPSIZE Statement

The HEAPSIZE statement defines the size of the application or DLL's local heap in bytes. This value affects the size of the default data segment (DGROUP). The default without HEAPSIZE is that no local heap is created.

Syntax

HEAPSIZE {bytes|MAXVAL}

Remarks

The bytes field accepts a positive integer in decimal or C-language notation. The limit is MAXVAL; if bytes exceeds MAXVAL, the excess is not allocated.

MAXVAL is a keyword that sets the heap size to 64K minus the size of DGROUP.

Example

The following example sets the local heap to 4000 bytes:

HEAPSIZE 4000