assert_eq2 Function

public function assert_eq2(n1, n2, string)

Arguments

Type IntentOptional AttributesName
integer, intent(in) :: n1
integer, intent(in) :: n2
character(len=*), intent(in) :: string

Return Value integer


Contents

Source Code


Source Code

	FUNCTION assert_eq2(n1,n2,string)
	CHARACTER(LEN=*), INTENT(IN) :: string
	INTEGER, INTENT(IN) :: n1,n2
	INTEGER :: assert_eq2
	if (n1 == n2) then
		assert_eq2=n1
	else
		write (*,*) 'nrerror: an assert_eq failed with this tag:', &
			string
		STOP 'program terminated by assert_eq2'
	end if
	END FUNCTION assert_eq2