Re: pattern for an error



To use product names (rather than the PGM= name from JCL).

For the "MVS" environment (including OS/390, z/OS - but not VSE),

Any compiler from VS COBOL II, R1 and later will allow END-IF. (VS COBOL II,
R1, R1.2, and R2 were '74 Standard compilers. VS COBOL II R3.0 and later
support eh '85 Standard). They also support - as an extension - NEXT SENTENCE
in an IF that ends with END-IF. Support for END-xxxx syntax is available even
when CMPR2 is used to emulate a '74 Standard compiler - sort-of.

Any compiler from OS/VS COBOL or earlier will NOT support END-IF (or any other
END-xxxx syntax).

***

Most (but certainly NOT ALL) code with
GO TO NNN-PARA-NAME-EXIT
syntax in it (especially if coded in all CAPS) was PROBABLY originally coded for
OS/VS COBOL or someone who was trained on OS/VS COBOL (or earlier). If that
is/was the case, then you will NOT see

GO TO NNN-PARA-NAME-EXIT

In an IF statement that is terminated by END-IF. If you see the combination of
that type of GO TO (especially in CAPS and END-IF), the changes are medium-good
that you are looking at code that has been maintained (in the last 20 years) but
never really "upgraded" to current coding techniques.

All of this is VAST generalizations and many exceptions do exist (on IBM
mainframes and elsewhere).

--
Bill Klein
wmklein <at> ix.netcom.com
"Howard Brazee" <howard@xxxxxxxxxx> wrote in message
news:9v9r34li5gfth17dttv7mu7f62587uv7el@xxxxxxxxxx
On Wed, 28 May 2008 17:36:48 +0000 (UTC), docdwarf@xxxxxxxxx () wrote:

IF FILE-STATUS-OK
CONTINUE
ELSE
GO TO BAD-FILE-STATUS
END-IF.

Wait a moment... how did IKFCBL00 compile that?

I don't know what IKFCBL00 is, but my IBM compiler will compile it.
But the people who code with Go To are also the people who don't use
END-IF.


.



Relevant Pages

  • Re: C03 abend when omitting CEE.SCEERUN from JCL
    ... The AMODE, RMODE, RENT, and RES information are link-edit information, not ... "compiler option" information. ... VS Cobol Program is actually OS/VS Cobol (amblist shows 5740CB103 as ... Do you mean VS COBOL II or OS/VS COBOL? ...
    (bit.listserv.ibm-main)
  • Re: Fw: 31 bit addressing issue
    ... Having an OS/VS COBOL program call an LE-COBOL program is the PRIME time ... with the wrong compiler options with such link-edit attributes) ... COBOL program trying to statically call an Enterprise COBOL subprogram. ...
    (bit.listserv.ibm-main)
  • Fw: 31 bit addressing issue
    ... Having an OS/VS COBOL program call an LE-COBOL program is the PRIME time ... Dynamic CALLs in COBOL (either DYNAM compiler option or CALL identifier) ... COBOL program trying to statically call an Enterprise COBOL subprogram. ...
    (bit.listserv.ibm-main)
  • Re: Is it always possible to write a COBOL program using only 1 sentence per paragraph?
    ... > available with your compiler. ... > to an EXIT PERFORM would do the conversion correctly. ... END-IF ... I'm supposed to accept COBOL ...
    (comp.lang.cobol)
  • Re: As I read the announcement ...
    ... it won't be "all that long" until Enterprise COBOL will be supported there. ... If you need an updated VM compiler, have you communicated your need to IBM ... > earlier post of yours thought that we would see COBOL for z/VM 4.0. ... >> For sites with such OS/VS COBOL source code, ...
    (comp.lang.cobol)