Destroy file.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(file_object), | intent(inout) | :: | self | File object. |
elemental subroutine destroy(self)
!< Destroy file.
class(file_object), intent(inout) :: self !< File object.
type(file_object) :: fresh !< Fresh instance of file object.
self = fresh
if (allocated(self%file_name)) deallocate(self%file_name)
endsubroutine destroy