TypeCobol
TypeCobol copied to clipboard
Bug in picture string based on a REPLACE operation
Describe the bug Our parser does not handle replace operations over PictureCharacterString
To Reproduce (Type)Cobol code that cause the bug : (if any)
IDENTIFICATION DIVISION.
PROGRAM-ID. MyPgm.
REPLACE ==toReplace== BY ==50==.
data division.
working-storage section.
01 var PIC X(toReplace).
END PROGRAM MyPgm.
The parser will fail and return Line 6[19,30] <27, Error, Syntax> - Syntax error : Missing '(' or ')' in PICTURE string
because the REPLACE did not happen.
Expected behavior No error and correct picture definition (check DataDef and VariableSymbol)