Other Than cosmetics, and the already pointed out advantage, regarding initialization, there is no other advantage.
From a COBOL internal point of view each variable is allocated one after the other, aligning, and maybe formatting them where they should be, some compiling options can twist this behavior somehow. The compiler do not pay any attention to levels at this point, even more it generates at compile time what is know as a 'normalized' level from all the levels it founds on its passes through the source code
On the other hand from an application proggrammer point of view, it makes sense to GROUP variables according to their usage, context or whatever happens to be the reason the analist comes up with.
A word of caution here ... Some 'levels' have a particular usage already defined, for example, Levels 88, levels 66 AND level 77, regarding L 77, they may not be used as grouping levels. some of the others, including L 88 may be part of other group levels _________________ Best wishes,
May I know what is the significance of having a single Level 1 variables in the working storage section over, having more number of Level 1 variables.
Please come up with ur views.
Thanks,
Ramakrishnan
See also the discussion on level 77...
Each 01 level is located on a full word boundary. The wasted space may have been a consideration 30 years ago.
Knowing that difference may be important when examining dumps. If anyone still does that. Some people found it easier to scan words byte by byte and others found it easier to skip to the next fullword when encountering the next 01 level.
As is often the case with go-away-spammer-sucker retentive programmers probably someone got promoted to manager and promptly enshrined their own personal preference as law (standard).
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum