Topic
1 reply Latest Post - ‏2013-03-08T14:08:38Z by walexand
Bart.VanCampenhout_ASIST
5 Posts
ACCEPTED ANSWER

Pinned topic Evaluate ignored in Program Control Flow ?

‏2013-03-08T13:44:20Z |
Assume this piece of COBOL code (Single function):

A-002.
PERFORM ERR-PROC.
EVALUATE BVCVAR
WHEN 0 PERFORM B-001
WHEN OTHER PERFORM ERR-PROC
END-EVALUATE.

It seems that the performs from within the EVALUATE statement are not taken into account for the "Program Control Flow" view.
See the attached screenshot to clarify this.

Did anyone experience this too ?

Would this be a bug ? Unsupported feature ?

FYI: Full Cobol Program:

IDENTIFICATION DIVISION.
PROGRAM-ID. BVC00001.
*
ENVIRONMENT DIVISION.
CONFIGURATION SECTION.
SOURCE-COMPUTER. IBM-3090-XA.
OBJECT-COMPUTER. IBM-3090-XA.
SPECIAL-NAMES.
DECIMAL-POINT IS COMMA.
*
DATA DIVISION.
WORKING-STORAGE SECTION.
01 BVCVAR PIC 9(08) VALUE 5.

LINKAGE SECTION.

PROCEDURE DIVISION.
MAIN.
PERFORM A-001

IF BVCVAR > 0
THEN PERFORM A-002
END-IF.

IF BVCVAR > 0
THEN PERFORM A-003
END-IF.

GOBACK.

A-001.
PERFORM ERR-PROC.
DISPLAY "A-001".

A-002.
PERFORM ERR-PROC.
EVALUATE BVCVAR
WHEN 0 PERFORM B-001
WHEN OTHER PERFORM ERR-PROC
END-EVALUATE.

A-003.
.
B-001.
.
ERR-PROC.
.
Updated on 2013-03-08T14:08:38Z at 2013-03-08T14:08:38Z by walexand