HP Fortran Programmer's Reference (September 2007)

HP Fortran statements
NAMELIST
Chapter 10 403
NAMELIST
Names a group of variables for I/O processing.
Syntax
NAMELIST /
group-name
/
var-list
[ [ ,]/
group-name
/
var-list
]...
group-name
is a unique namelist group name.
var-list
is a comma-separated list of scalar and array variable names.
Description
The NAMELIST statement declares
var-list
as a namelist group and associates the group
with
group-name
.
Variables appearing in
var-list
may be of any type, including objects of derived types or
their components, saved variables, variables on the local stack, and subroutine parameters.
The following, however, are not allowed:
Record or composite references
Pointers or their targets
Automatic objects
Allocatable array
Character substrings
Assumed-size array parameters
Adjustable-size array parameters
Assumed-size character parameters
Individual components of a derived type object
The
var-list
explicitly defines which items may be read or written in a namelist-directed I/O
statement. It is not necessary for every item in
var-list
to be defined in namelist-directed
input, but every input item must belong to the namelist group. The order of items in
var-list
determines the order of the values written in namelist-directed output.
More than one NAMELIST statement with the same
group-name
may appear within the same
scoping unit. Each successive
var-list
in multiple NAMELIST statements with the same
group-name
is treated as a continuation of the list for
group-name
.