int4_1D_or_int4_1D Function

public function int4_1D_or_int4_1D(a, b) result(r)

Bitwise 'OR' over two 1D integer array of kind 4

Arguments

Type IntentOptional AttributesName
integer(kind=4), intent(in), dimension(:):: a
integer(kind=4), intent(in), dimension(:):: b

Return Value integer(kind=4), dimension(size(a))


Called by

proc~~int4_1d_or_int4_1d~~CalledByGraph proc~int4_1d_or_int4_1d int4_1D_or_int4_1D interface~operator(.or.) operator(.or.) interface~operator(.or.)->proc~int4_1d_or_int4_1d

Contents

Source Code


Source Code

        function int4_1D_or_int4_1D(a, b) result(r)
          !< Bitwise 'OR' over two 1D integer array of kind 4
            implicit none
            integer(kind=4), dimension(:), intent(in) :: a
            integer(kind=4), dimension(:), intent(in) :: b
            integer(kind=4), dimension(size(a)) :: r
            if (size(a) /= size(b)) then
                print *, "Error: Sizes of arrays being 'or'ed should be the same."
                stop
            end if
            r = ior(a, b)
        end function int4_1D_or_int4_1D