GILDAS Fortran derived type

#
GILDAS Fortran derived type

      type :: gildas
        sequence
        character(len=filename_length)   :: file = ' '  ! File name
        type (strings)       :: char                    !
        type (location)      :: loca                    !
        type (gildas_header_v2) :: gil                  !
        integer(kind=index_length) :: blc(gdf_maxdims) = 0       ! Bottom left corner
        integer(kind=index_length) :: trc(gdf_maxdims) = 0       ! Top right corner
        integer(kind=4) :: header = 0                   ! Defined / Undefined
        integer(kind=4) :: status = 0                   ! Last error code
        real,         pointer :: r1d(:)       => null() ! Pointer to 1D data
        real(kind=8), pointer :: d1d(:)       => null()
        integer,      pointer :: i1d(:)       => null()
        real,         pointer :: r2d(:,:)     => null() ! Pointer to 2D data
        real(kind=8), pointer :: d2d(:,:)     => null()
        integer,      pointer :: i2d(:,:)     => null()
        real,         pointer :: r3d(:,:,:)   => null() ! Pointer to 3D data
        real(kind=8), pointer :: d3d(:,:,:)   => null()
        integer,      pointer :: i3d(:,:,:)   => null()
        real,         pointer :: r4d(:,:,:,:) => null() ! Pointer to 4D data
        real(kind=8), pointer :: d4d(:,:,:,:) => null()
        integer,      pointer :: i4d(:,:,:,:) => null()
      end type gildas

      type :: strings
        sequence
        character(len=12) :: type    = 'GILDAS_IMAGE'  !     Image Type (see ITYP)
        character(len=12) :: unit    = ' '             !     Data Units (see IUNI)
        character(len=12) :: code(gdf_maxdims) = ' '   !     Axis codes (see ICOD)
        character(len=12) :: syst    = ' '             !     Coordinate system (see ISYS)
        character(len=12) :: name    = ' '             !     Source name (see ISOU)
        character(len=12) :: line    = ' '             !     Line name (see ILIN)
        ! For Even GDF_MAXDIMS only ! character(len=4)  :: pad_char
      end type strings

      type :: location
        sequence
        integer(kind=address_length) :: addr = 0  ! Address of image
        integer(kind=size_length) :: size = 0     ! Size of image
        integer :: islo         = 0               ! Image Slot number
        integer :: mslo         = 0               ! Memory Slot number
        logical :: read         = .true.          ! ReadOnly status
        logical :: getvm        = .false.         ! Memory / File indicator
        integer(kind=size_length) :: al64 = 0     ! Padding required for alignment
      end type location