copy_stencilElement Subroutine

private subroutine copy_stencilElement(left, right)

This function provides copy assigment for tem_stencilElement_type

Arguments

Type IntentOptional Attributes Name
type(tem_stencilElement_type), intent(out) :: left

tem_stencilElement to copy to

type(tem_stencilElement_type), intent(in) :: right

tem_stencilElement to copy from


Called by

proc~~copy_stencilelement~~CalledByGraph proc~copy_stencilelement copy_stencilElement interface~assignment(=) assignment(=) interface~assignment(=)->proc~copy_stencilelement

Source Code

  subroutine copy_stencilElement(left, right)
    ! -------------------------------------------------------------------- !
    !> tem_stencilElement to copy to
    type(tem_stencilElement_type), intent(out) :: left
    !> tem_stencilElement to copy from
    type(tem_stencilElement_type), intent(in) :: right
    ! -------------------------------------------------------------------- !
    ! -------------------------------------------------------------------- !

    left%QQN = right%QQN
    if ( allocated(right%tIDpos) ) then
      allocate(left%tIDpos(size(right%tIDpos)))
      left%tIDpos = right%tIDpos
    end if

    left%headerPos = right%headerPos

    if ( allocated(right%totalPos) ) then
      allocate(left%totalPos(size(right%totalPos)))
      left%totalPos = right%totalPos
    end if

  end subroutine copy_stencilElement