Anonymous user
Memory allocation: Difference between revisions
→{{header|REXX}}: added more verbage in the REXX section header. -- ~~~~
(+ D entry) |
(→{{header|REXX}}: added more verbage in the REXX section header. -- ~~~~) |
||
Line 984:
=={{header|REXX}}==
There is no explicit memory allocation in the REXX language, variables are
<br>Most
<br>One particular REXX has predefined and limited amount of free storage.
<lang rexx>Axtec_god.3='Quetzalcoatl ("feathered serpent"), god of learning, civilization, regeneration, wind and storms'</lang>
There is no explicit way to de-allocate memory, but there is a DROP statement that "un-defines" a REXX variable and it's memory is then free to be used for other variables, provided that free memory isn't too fragmented.
<lang rexx>drop xyz NamesRoster j k m caves names. Axtec_god. Hopi Hopi
/* it's not considered an error to DROP a variable that isn't defined.*/</lang>
Any variables (that are non-exposed) which are defined (allocated) in a procedure/subroutine/function will be un-allocated at the termination (completion, when it RETURNS or EXITs) of the procedure/subroutine/function.▼
▲Any variables (that are non-exposed) which are defined (allocated) in a procedure/subroutine/function will be un-allocated at the termination of the procedure/subroutine/function.
<br><br>
|