For Programmers: Free Programming Magazines  


Home > Archive > Cobol > March 2008 > Re: RW on Working-Storage (was: J4 - presentation/discussion on "Future of the C









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: RW on Working-Storage (was: J4 - presentation/discussion on "Future of the C
Robert

2008-03-12, 9:56 pm

On Wed, 12 Mar 2008 13:21:03 GMT, "William M. Klein" <wmklein@nospam.netcom.com> wrote:

><snip>
>
>Robert,
> Can you point me to where in "the Standard" ('85 or '02) that it says this?
>(Certainly it is NOT true in the '02 Standard where you specifically can use the
>ALLOCATE/FREE statements to dynamically get storage in Working-Storage Section.)
>To the best of my knowledge, no previous ANSI/ISO Standard ever said this
>either. In fact, as I recall, when, where, and how storage was allocated by
>some vendors differed, for example, for 01-levels and 77-levels.


8.6.3 of the 2002 standard

Data items and file connectors defined in the working-storage, communication, or file
section of a source element that is not an initial program are static items. Also, screen
item attributes in a source element that is not an initial program are treated as static
items. These items are set to their initial state each time the runtime element or object
containing them is set to its initial state, as described in 14.5.2.1.2.1, Initial state,
and in 14.5.2.2, Initial state of object data. They are allocated no later than
immediately before initialization and persist to the first of the
following:
— the end of the run unit,

A based entry is a data description entry in the working-storage section, local-storage
section, or linkage section that is described with a BASED clause. A based entry is not
initially associated with an actual data item. An association is established linking the
based entry to actual data when its implicit data-address pointer is assigned the address
of an existing data item or assigned the address of storage obtained with an ALLOCATE
statement. This association establishes a based data item.
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com