destroy Subroutine

private pure subroutine destroy(self)

Destroy element.

Arguments

Type IntentOptional AttributesName
class(element_object), intent(inout) :: self

element.


Source Code


Source Code

   pure subroutine destroy(self)
   !< Destroy element.
   class(element_object), intent(inout) :: self !< element.

   if (allocated(self%string)) deallocate(self%string)
   if (allocated(self%color_fg)) deallocate(self%color_fg)
   if (allocated(self%color_bg)) deallocate(self%color_bg)
   if (allocated(self%style)) deallocate(self%style)
   endsubroutine destroy