Re: Dynamic memory in standard COBOL; using large data fields
- From: "William M. Klein" <wmklein@xxxxxxxxxxxxxxxxx>
- Date: Tue, 31 May 2005 18:02:07 GMT
Slight correction or clarification to Chuck's post.
The '02 Standard *does* introduce the ALLOCATE and FREE statements to do what
you are calling "getmain" and "freemain" (IBM mainframe terminology - I don't
know how common this is). It also includes POINTER data items and based data.
What the (currently under development) '08 Standard will introduce is "dynamic
capacity tables" (and any-length items). The former will provide a method for a
new type of OCCURS where a table will "grow" and/or shrink - along with the
storage it uses.
--
Bill Klein
wmklein <at> ix.netcom.com
"Chuck Stevens" <charles.stevens@xxxxxxxxxx> wrote in message
news:d7i4em$22fo$1@xxxxxxxxxxxxxxxxxxxxxxx
>
> "clvrmnky" <clvrmnky-uunet@xxxxxxxxxxxxxxxxxxxx> wrote in message
> news:aR%me.8324$5u4.27086@xxxxxxxxxxxxxxxxx
>> My review of available literature seems to indicate that COBOL-85 does
>> not support the notion of dynamic memory. That is, there is no standard
>> malloc or calloc style keywords or calls I can make to allocate and grow
>> a hunk of memory for an application.
>
> Indeed, ANSI X3.23-1985 provides neither standard syntax nor standard
> functions to provide this capability. Nor does ISO/IEC 1989:2002.
>
> The COBOL standard being developed for approval in 2008 includes in the
> current draft both "any-length elementary items" and "dynamic-capacity
> tables", alone or in combination. This isn't so much based on the C or
> Pascal models of the "heap" as it is oriented toward adding true
> variable-length capabilities to existing COBOL applications.
>
> -Chuck Stevens
>
>
.
- References:
- Dynamic memory in standard COBOL; using large data fields
- From: clvrmnky
- Re: Dynamic memory in standard COBOL; using large data fields
- From: Chuck Stevens
- Dynamic memory in standard COBOL; using large data fields
- Prev by Date: Re: How to stop UDP port 86 BroadCast
- Next by Date: Re: Dynamic memory in standard COBOL; using large data fields
- Previous by thread: Re: Dynamic memory in standard COBOL; using large data fields
- Next by thread: Re: Dynamic memory in standard COBOL; using large data fields
- Index(es):
Relevant Pages
|