assert_positive_i32_1 Subroutine

private subroutine assert_positive_i32_1(this, i)

Check if a integer (32 bits) array (rank 1) is positive.

Type Bound

tester_t

Arguments

Type IntentOptional Attributes Name
class(tester_t), intent(inout) :: this

The tester.

integer(kind=int32), intent(in), dimension(:) :: i

Value to check.


Called by

proc~~assert_positive_i32_1~~CalledByGraph proc~assert_positive_i32_1 tester::tester_t%assert_positive_i32_1 none~assert_positive tester::tester_t%assert_positive none~assert_positive->proc~assert_positive_i32_1 program~test_tester_05 test_tester_05 program~test_tester_05->none~assert_positive program~test_tester_1 test_tester_1 program~test_tester_1->none~assert_positive

Source Code

  subroutine assert_positive_i32_1(this, i)
    class(tester_t),              intent(inout)        :: this !< The tester.
    integer(int32), dimension(:), intent(in)           :: i    !< Value to check.

    this% n_tests = this% n_tests + 1

    if ( minval(i) < 0 ) then
       this% n_errors = this% n_errors + 1
    end if

  end subroutine assert_positive_i32_1