Destroy the node and its subsequent ones.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(dictionary_node), | intent(inout), | pointer | :: | node | The node. |
pure recursive subroutine destroy_dictionary_node(node)
!---------------------------------------------------------------------------------------------------------------------------------
!< Destroy the node and its subsequent ones.
!---------------------------------------------------------------------------------------------------------------------------------
type(dictionary_node), pointer, intent(inout) :: node !< The node.
!---------------------------------------------------------------------------------------------------------------------------------
!---------------------------------------------------------------------------------------------------------------------------------
if (associated(node)) then
call node%destroy
call destroy_dictionary_node(node=node%next)
node%previous => null()
deallocate(node)
node => null()
endif
!---------------------------------------------------------------------------------------------------------------------------------
endsubroutine destroy_dictionary_node