Subroutine to copy an array
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(ndarray), | intent(inout) | :: | this | |||
class(pf_encap_t), | intent(in) | :: | src | |||
integer, | intent(in), | optional | :: | flags |
subroutine ndarray_copy(this, src, flags)
class(ndarray), intent(inout) :: this
class(pf_encap_t), intent(in ) :: src
integer, intent(in ), optional :: flags
select type(src)
type is (ndarray)
this%flatarray = src%flatarray
class default
stop "TYPE ERROR"
end select
end subroutine ndarray_copy