COBOL

COBOL

COBOL

COBOL is responsible for the efficient, reliable, secure, and unseen day-to-day operations of the world's economy.

 View Only
  • 1.  Abbr. 'S' in option TEST interferes with EJPD

    Posted Thu November 03, 2016 04:07 AM

    Here's what I found in the COBOL 5 compiler (5.1.1 & 5.2.0):

    Invocation parameters:                                           
     ...TEST(S,EJPD)

    results in:

    Options in effect:

    ...

      TEST(NOEJPD,SOURCE)

    ...

    I didn't expect the NOEJPD, I expected EJPD.

    Using TEST(EJPD,S) works fine, the result: TEST(EJPD,SOURCE).

    Seems like the 'S' (and 'NOS') when used as the first sub-option, sets the TEST sub-option EJPD to its default: NOEJPD.

    RenéBeurskens


  • 2.  Re: Abbr. 'S' in option TEST interferes with EJPD

    Posted Thu November 03, 2016 03:36 PM

    They are positional. When the invalid (in that position) S was encountered, what you have provided was abandoned and you got the default values for TEST, which is NOEJPD,SOURCE.

    BillWoodger


  • 3.  Re: Abbr. 'S' in option TEST interferes with EJPD

    Posted Thu November 03, 2016 04:10 PM

    Ah. Missed that you tried NOS. So since SOURCE is the second value, when it arrives there can't be another, so yes, you get the default.

    However, just tried with V4... and the behaviour is different, EJPD,NOHOOK got me NOHOOK (not default) SEPARATE (default) and EJPD. Even using NOSEP after EJPD gets me NOSEPARATE, so for V4 not relevant that it is an abbreviation.

     

    So forget all that hat I said except this last bit :-)

    BillWoodger


  • 4.  Re: Abbr. 'S' in option TEST interferes with EJPD

    Posted Wed November 23, 2016 01:15 PM

    Please report this problem to IBM service, you have found a defect in the processing of the TEST compiler option!

     

    Tom

    Tom.Ross