Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(llist), | intent(inout) | :: | lst |
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
type(llist_node), | public, | pointer | :: | this |
integer function size(lst)
type(llist), intent(inout) :: lst
type(llist_node), pointer :: this
size = 0
this => lst%begin
do
if (.not. associated(this)) exit
size = size + 1
this => this%next
end do
end function size