abort_prog.h File Reference


Detailed Description

Macro to abort a program on error.

#include <stdio.h>
#include <oski/common.h>

Go to the source code of this file.

Defines

#define INC_UTIL_ABORT_PROG_H
 tests/test_util.h included.
#define ABORT(cond, method, err)
 If the given condition is true, calls the generic BeBOP error reporting macro, OSKI_ERR, and aborts the current program with exit code 1.


Define Documentation

#define ABORT cond,
method,
err   ) 
 

Value:

if(cond) { \
        fprintf( stderr, "*** Error condition '%s' detected ***\n", \
            MACRO_TO_STRING(cond) ); \
        OSKI_ERR(method, err); \
        exit(1); \
    }
If the given condition is true, calls the generic BeBOP error reporting macro, OSKI_ERR, and aborts the current program with exit code 1.

Parameters:
[in] cond A boolean condition expression.
[in] method Calling function from which to report the error. This parameter is converted to a string via MACRO_TO_STRING(method).
[in] err BeBOP error code.


Generated on Wed Sep 19 16:41:21 2007 for BeBOP Optimized Sparse Kernel Interface Library by  doxygen 1.4.6