Dirac - A Video Codec
Created by the British Broadcasting Corporation.
Go to the documentation of this file.
37 #ifndef DIRAC_ASSERTIONS_H
38 #define DIRAC_ASSERTIONS_H
43 #define cmpCOND( exp, trueRes, falseRes ) ( (exp) ? (trueRes) : (falseRes) )
46 #define ERREXP(exp,errfn,text) cmpCOND((exp), ((void)0), errfn(__FILE__,__LINE__,text))
49 #define ASSERT(exp) ERREXP(exp,dirac_assert,NULL)
52 #define ASSERTM(exp,text) ERREXP(exp,dirac_assert,text)
60 #define TEST(exp) ASSERT(exp)
61 #define TESTM(exp,text) ASSERTM(exp,text)
62 #define REPORT(exp) ASSERT(exp)
63 #define REPORTM(exp,text) ASSERTM(exp,text)
66 #define TESTM(exp,text)
67 #define REPORT(exp) ERREXP(exp,dirac_report,NULL)
68 #define REPORTM(exp,text) ERREXP(exp,dirac_report,text)
73 void dirac_assert(
const char *p_fname,
int line_number,
const char *p_mess);
76 void dirac_report(
const char *p_fname,
int line_number,
const char *p_mess);
© 2004 British Broadcasting Corporation.
Dirac code licensed under the Mozilla Public License (MPL) Version 1.1.
HTML documentation generated by Dimitri van Heesch's
excellent Doxygen tool.