array_list_concat Function

private pure function array_list_concat(lhs, rhs) result(concat)

Arguments

Type IntentOptional AttributesName
class(array_list), intent(in) :: lhs

The list

class(ordered), intent(in) :: rhs

The object being concatenated to the list

Return Value class(ordered), allocatable

The concatenated object. Will have dynamic type array_list.

Description

Join this list with an ordered object, returning the result. The contents of the returned object are ordered such that applying pop until it is empty would return items in the same order as calling pop until the list is empty and then until the second object is empty.


Source Code

  pure function array_list_concat(lhs, rhs) result(concat)
    !* Author: Chris MacMackin
    !  Date: March 2016
    !
    ! Join this list with an [[ordered]] object, returning the result. The 
    ! contents of the returned object are ordered such that applying 
    ! [[ordered:pop]] until it is empty would return items in the same order as 
    ! calling [[ordered:pop]] until the list is empty and then until the second 
    ! object is empty.
    !
    class(array_list), intent(in) :: lhs !! The list
    class(ordered), intent(in) :: rhs !! The object being concatenated to the list
    class(ordered), allocatable :: concat
     !! The concatenated object. Will have dynamic type [[array_list]]. 
  end function array_list_concat