Runge-Kutta-Simulation/AppleX/INCLUDE/ASSERT.H

9 lines
203 B
C++
Raw Normal View History

2015-02-11 18:34:08 +00:00
#ifndef NDEBUG
#ifndef stderr
#include <stdio.h>
#endif
#define assert(x) if (!(x)) {fprintf(stderr,"Assertion failed: x, file %s, line %d\n",__FILE__,__LINE__); exit(1);}
#else
#define assert(x)
#endif