https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119632

--- Comment #8 from James K. Lowden <jklowden at gcc dot gnu.org> ---
> But it should really do that - and allow it for _any_ other standard, not 
> only ibm.

We don't want to let nonstandard syntax slip by unnoticed.  

IBM Linux COBOL allows SECTION segment numbers as syntax, and ignores them. 
GCC COBOL (now) does the same, and so we allow it.  

As I read 

https://www.microfocus.com/documentation/visual-cobol/vc90/DevHub/HRLHLHSEGM01U006.html

that compiler makes some subtle runtime initialization decisions based on
whether the segment is fixed or independent.  IMO it's better to say we don't
support that functionality -- and syntax -- than to accept it with or without a
warning, because it invites a runtime error.  

This feature was marked obsolete in 1985. And for good reason: it's one of the
few places where the underlying machine is exposed as COBOL syntax, and it's
exceedingly odd.  The value of the number larger or smaller than 50 determines
the effect.  

I do not foresee a day when we would actually implement what MF describes
unless a paying client wanted it.  I would expect if such code were encountered
during a migration, that it would be easier to exclude the dependency than to
emulate the behavior and test for it.

Reply via email to