_SAVE_ARG_STACK - save savable descriptors from Arg Stack.

(GCOS8 only)

Usage:

C:
   #include <climb.h>
   _save_arg_stack();
PL6:
   DCL X_SAVE_ARG_STACK ENTRY(0);
   X_SAVE_ARG_STACK();

Description:

"_save_arg_stack" copies all savable descriptors from the Argument Stack to safe storage. Typically, you would do this just before an OCLIMB. You should not call any of the other segment allocation routines (like "_gtseg" or "_frseg") after calling "_save_arg_stack", until you have done a "restore_arg_stack" after returning from the OCLIMB.

It is not an error if you call "save_arg_stack" several times in succession. For example, if you call it explicitly just before leaving a domain, and then the domain exit routine also calls it, you won't run into trouble.

"_save_arg_stack" does not attempt to save unsavable or unknown descriptors. Instead, it saves null descriptors in their place. (For a discussion of unsavable and unknown descriptors, see "expl nsc lib _gtseg".)

Notes:

C programmers never have to call "_save_arg_stack" explicitly because the C library routines do it for you.

See Also:

expl nsc lib _gtseg
general SEGID allocation routine.
expl nsc lib _restore_arg_stack
for restoring the Argument Stack after an OCLIMB.

Copyright © 1996, Thinkage Ltd.