Developer Guide and Reference

ID 767251
Date 10/31/2024
Public
Document Table of Contents

Padding Specifier (PAD=)

The padding specifier temporarily changes the padding mode set when the file was opened. PAD= cannot appear in an I/O control list of a WRITE statement. This specifier takes the following form:

PAD=c-expr

c-expr

Is a scalar default character expression that evaluates to 'YES' or 'NO'.

Trailing blanks in the expression are ignored. The values specified are without regard to case.

If PAD= does not appear, the padding mode is unchanged. If a PAD= specifier appears, a namelist or a format specifier must also appear in the I/O control list.

The padding mode tells the runtime library whether the processor should provide blank padding during formatted input if the input list and the format specification for the input list items require more characters that the input record contains.

If the mode is 'YES', blanks are provided for padding. If the mode is 'NO', no padding is provided.