![]() |
StackSpace |
||||
Header: | MacMemory.h | Carbon status: | Supported | |
Returns the amount of space between the bottom of the stack and the top of the application heap.
SInt32 StackSpace ();
The current amount of stack space, in bytes, between the current stack pointer and the application heap.0
Usually you determine the maximum amount of stack space needed before you ship your application. Thus this function is generally useful only during debugging to determine how big to make the stack. However, if your application calls a recursive function that conceivably could call itself many times, that function should keep track of the stack space and take appropriate action if it becomes too low.
Call the function MemError to get the result code. See
Supported in Carbon. Available in CarbonLib 1.0 and later when InterfaceLib 7.1 or later is installed. Exported by CarbonLib 1.0 and later and by InterfaceLib 7.1 and later.