next Function

private function next(this, if_exhausted) result(res)

Return the next Token and increment the iterator.

If the iterator is exhausted, this function throws an error unless the argument if_exhausted is present, which is then returned instead.

To view the next Token without incrementing the iterator use glimpse.

Type Bound

TokenIterator_t

Arguments

Type IntentOptional Attributes Name
class(TokenIterator_t), intent(inout) :: this
character(len=*), intent(in), optional :: if_exhausted

Return Value character(len=:), allocatable


Contents