ContentsIndexPreviousNext

G.2 COMP-1 and COMP-2 are Floating-Point

The treatment of COMP-1 (aka COMPUTATIONAL-1) and COMP-2 (aka COMPUTATIONAL-2) is different in IBM DOS/VS COBOL. They are equivalent to FLOAT and DOUBLE, respectively, and they cannot be used with PICTURE phrases.

ACUCOBOL-GT already has a command-line option ("-Df") to specify that COMP-1 and COMP-2 are to be treated as in IBM DOS/VS COBOL. Therefore, it is only necessary to enable the "-Df" option automatically in the IBM DOS/VS COBOL compatibility mode.


Note: The "-Cv" option AUTOMATICALLY enables the "-Df" option.
Take care to observe the proper syntax and usage of COMP-1 and COMP-2 variables for the mode in effect.