New reserved words
If your programs
use any of the new reserved words as user-defined words (such as data
item names or paragraph names), then those words must be changed.
You can do something similar to what CCCA does and just add a suffix
such as
-85
to all instances of the word. For example:77 VOLATILE PIC S9(9) BINARY.
Move 0 TO VOLATILE.
To compile with Enterprise COBOL 5 or 6, change
it to: 77 VOLATILE-85 PIC S9(9) BINARY.
Move 0 TO VOLATILE-85.
The new reserved words in Enterprise COBOL V6 are ALLOCATE, DEFAULT, END-JSON, FREE, JSON, JSON-CODE, and JSON-STATUS.
You can use CCCA to convert the reserved words automatically. For more information about the CCCA tool, see Conversion tools for source programs.
CCCA is updated for reserved word conversions for Enterprise COBOL V5.1 by the PTF for APAR PM86253. For V5.2, CCCA is updated for reserved word conversions by the PTF for APAR PI32750. For V6.1, CCCA is updated for reserved word conversions by the PTF for APAR PI55980.
The following table shows the reserved words added to each subsequent release of COBOL. For a complete list of reserved words, see COBOL reserved word comparison.
Compiler | Reserved word |
---|---|
COBOL/370 V1R1 | FUNCTION, PROCEDURE-POINTER |
COBOL for MVS & VM V1R2 | CLASS-ID, METACLASS, RECURSIVE, END-INVOKE, METHOD, REPOSITORY, INHERITS, METHOD-ID, RETURNING, INVOKE, OBJECT, SELF, SUPER, LOCAL-STORAGE, OVERRIDE |
COBOL for OS/390® & VM V2R1 | Same as COBOL for MVS & VM |
COBOL for OS/390 & VM V2R2 | COMP-5, COMPUTATIONAL-5, EXEC, END-EXEC, SQL, TYPE, FACTORY |
COBOL for OS/390 & VM V2R2 with PQ49375 | EXECUTE |
Enterprise COBOL V3R1 | JNIENVPTR, NATIONAL, XML, END-XML, XML-EVENT, XML-CODE, XML-TEXT, XML-NTEXT, FUNCTION-POINTER |
Enterprise COBOL V3R4 | NATIONAL-EDITED, GROUP-USAGE |
Enterprise COBOL V4R1 | XML-NAMESPACE, XML-NAMESPACE-PREFIX, XML-NNAMESPACE, XML-NNAMESPACE-PREFIX |
Enterprise COBOL V4R2 | XML-SCHEMA Note: XML-INFORMATION
is added as a reserved word with APAR PM85035.
|
Enterprise COBOL V5R1 | XML-INFORMATION |
Enterprise COBOL V5R2 | VOLATILE |
Enterprise COBOL V6R1 | ALLOCATE, DEFAULT, END-JSON, FREE, JSON, JSON-CODE |
Enterprise COBOL V6R2 | JSON-STATUS |
Enterprise COBOL V6R3 | BYTE-LENGTH, JAVA, LIMIT, POINTER-32, UTF-8 |