-
Notifications
You must be signed in to change notification settings - Fork 25
Open
Labels
BugCobolUser VisibleVisible by the end user. Useful to priorize issueVisible by the end user. Useful to priorize issue
Milestone
Description
Describe the bug
When using a variable in condition instead of a DataCondition (Level-88), the parser does not emit any diagnostic.
To Reproduce
(Type)Cobol code that cause the bug : (if any)
IDENTIFICATION DIVISION.
PROGRAM-ID. TCOMFL06.
DATA DIVISION.
WORKING-STORAGE SECTION.
01 var1 PIC X.
88 cond1 VALUE 'A'.
88 cond1 VALUE 'B'.
PROCEDURE DIVISION.
IF (var1) THEN
DISPLAY "This is definitely wrong"
END-IF
GOBACK
.
END PROGRAM TCOMFL06.Expected behavior
Diagnostic expected at line 9 signaling an invalid condition.
Technical
New check to implement in CrossChecker. List all nodes that should be checked or find another way to factorize condition checks.
How to test automatically
Standard program parsing test.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
BugCobolUser VisibleVisible by the end user. Useful to priorize issueVisible by the end user. Useful to priorize issue