Leading Zero Specifier (LEADING_ZERO=)
The leading zero specifier temporarily changes the leading zero mode set when the file was opened. LEADING_ZERO= cannot appear in an I/O control list of a READ statement. This specifier takes the following form:
LEADING_ZERO=c-expr
c-expr |
Is a scalar default character expression that evaluates to 'PRINT', 'SUPPRESS', or 'PROCESSOR_DEFINED'. Trailing blanks in the expression are ignored. The values specified are without regard to case. |
If LEADING_ZERO= does not appear, the leading zero mode is unchanged for the statement. If a leading zero specifier appears, a namelist or a format specifier must also appear in the io-control-list.
In formatted output, the leading zero mode determines if optional leading zeros appear in formatted numeric output fields. They are printed if the mode is 'PRINT', they are not printed if the mode is 'SUPPRESS', and they may or may not appear if the mode is 'PROCESSOR_DEFINED', according to the rules for the format edit descriptor corresponding to each item in the output list.
If the LZ, LZP, or LZS edit descriptors are specified in the format of an output statement, they supersede the interpretation of the leading zero edit mode set with a LEADING_ZERO= speicifer in the io-control-list or when the file was opened.