Expressions used with VALUE clause
COBOL for Linux® on x86 does not support the use of expressions with the VALUE clause. The VALUE clause only supports literals. If an expression is used with the VALUE clause, the statement will be discarded and the following error message will be emitted.
$cat example.cbl
IDENTIFICATION DIVISION.
PROGRAM-ID. EXAMPLE.
ENVIRONMENT DIVISION.
CONFIGURATION SECTION.
DATA DIVISION.
WORKING-STORAGE SECTION.
01 exampleItem pic x(11) value "hello" & " world".
PROCEDURE DIVISION.
DISPLAY exampleItem.
STOP RUN.
IBM COBOL for Linux 1.2.0 compile started
0LineID Message code Message text
7 IGYDS1089-S "&" was invalid. Scanning was resumed at the next area "A" item,
level-number, or the start of the next clause.
-Messages Total Informational Warning Error Severe Terminating
0Printed: 1 1
End of compilation 1, program EXAMPLE, highest severity: Severe.
Return code 12
To resolve this issue, you need to remove the expression from the VALUE clause as the VALUE clause only supports literals.