WHEN-COMPILED

IBM DOS/VS COBOL contains a reserved word, WHEN-COMPILED, that can be used as the source of a MOVE statement. The value copied into the destination or destinations is a string of the form MM/DD/YYhh.mm.ss, representing the time and date when the compilation began, where

MM is the month (01 = Jan., 02 = Feb., etc.)
DD is the day (01 to 31, inclusive)
YY is the year, modulo 100 (99 for 1999, 00 for 2000, 01 for 2001, etc.)
hh is the hour, on a 24-hour clock (00-23)
mm is the minute (00-59)
ss is the second (00-59)

ACUCOBOL-GT does the same when it is in the IBM DOS/VS COBOL compatibility mode. However, ACUCOBOL-GT also allows the programmer to use WHEN-COMPILED wherever a string constant can be used, not just as the source of a MOVE statement.

Note: The ACUCOBOL-GT object file (.ACU) contains an embedded compilation time and date, which is used for other purposes but is identical to COMPILE-TIME.