C Library Functions  - unit_check_bad (3)

NAME

unit_check_bad(3f) - [M_verify] call command "goodbad NAME bad" and stop program (LICENSE:PD)

CONTENTS

Synopsis
Description
Examples
Author
License

SYNOPSIS

subroutine unit_check_bad(name,opts,msg)

    character(len=*),intent(in) :: name
    character(len=*),intent(in),optional :: opts
    character(len=*),intent(in),optional :: msg

DESCRIPTION

unit_check_bad(3f) calls the shell command

        goodbad NAME bad [opts]

and stops the program. It is just a shortcut for calling call unit_check(name,.false.) call unit_check_done(name,opts,msg)

EXAMPLES

Sample program:

    program demo_unit_check_bad
    use M_verify, only: unit_check_start
    use M_verify, only: unit_check
    use M_verify, only: unit_check_good, unit_check_bad

implicit none integer :: x x=10 call unit_check_start(’myroutine’)

call unit_check(’myroutine’, x > 3 ,’test if big enough’) call unit_check(’myroutine’, x < 100 ,’test if small enough’)

if(x /= 0)then call unit_check_bad (’myroutine’,msg=’checks on "myroutine" failed’) ! program execution stopped endif

end program demo_unit_check_bad

AUTHOR

John S. Urban

LICENSE

Public Domain


Nemo Release 3.1 unit_check_bad (3) July 22, 2023
Generated by manServer 1.08 from 295a723b-8733-4028-9844-f9ee90fdf122 using man macros.