swig-fortran / swig

This fork of SWIG creates Fortran wrapper code from C++ headers.
http://www.swig.org
Other
42 stars 11 forks source link

Change internal 'section' names in fortran wrapper code #69

Closed sethrj closed 5 years ago

sethrj commented 6 years ago

The fortran standard uses slightly different terminology and grouping than our sections that get written to the .f90 file.

MODULE module-name
 USE ...
 IMPORT ...
 IMPLICIT ...
 [declaration-construct]
CONTAINS
 module-subprogram
END MODULE

where declaration-construct is derived types, enums, interfaces, parameters, procedure declarations, etc. Currently we break these out into more rigid boundaries.

Name Description
fbegin Code before the module statement
fmodule Start of module:
fpublic Public interface functions
fparams Enums and parameters
ftypes Fortran classes
finterfaces Fortran class constructors
fwrapper Fortran subroutines (proxy code)
sethrj commented 5 years ago

Implemented this a while back.