geometry_destroy Subroutine

private subroutine geometry_destroy(this)

Clean up allocated memory in geometry_type

Type Bound

geometry_type

Arguments

Type IntentOptional Attributes Name
class(geometry_type), intent(inout) :: this

Called by

proc~~geometry_destroy~~CalledByGraph proc~geometry_destroy geometry_type%geometry_destroy proc~config_destroy mqc_config_t%config_destroy proc~config_destroy->proc~geometry_destroy proc~initialize_system_geometry initialize_system_geometry proc~initialize_system_geometry->proc~geometry_destroy proc~molecule_destroy molecule_t%molecule_destroy proc~molecule_destroy->proc~geometry_destroy

Source Code

   subroutine geometry_destroy(this)
      !! Clean up allocated memory in geometry_type
      class(geometry_type), intent(inout) :: this
      if (allocated(this%elements)) deallocate (this%elements)
      if (allocated(this%coords)) deallocate (this%coords)
      if (allocated(this%comment)) deallocate (this%comment)
      this%natoms = 0
   end subroutine geometry_destroy