Check error handle status
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(c_ptr), | value | :: | verror |
function check_error_api(verror) result(status) & & bind(C, name=namespace//"check_error") type(c_ptr), value :: verror type(vp_error), pointer :: error integer(c_int) :: status if (c_associated(verror)) then call c_f_pointer(verror, error) if (allocated(error%ptr)) then status = 1 else status = 0 end if else status = 2 end if end function check_error_api