Engauge Digitizer  2
 All Classes Files Functions Variables Enumerations Enumerator Friends Pages
EngaugeAssert.h
1 #ifndef ENGAUGE_ASSERT_H
2 #define ENGAUGE_ASSERT_H
3 
4 #include "LoggerUpload.h"
5 #include <QtGlobal>
6 
7 // For the replacements below, the qt_noop part prevents 'missing return' compiler warnings at the ends of functions
8 inline void engauge_noop(bool) {}
9 
14 #define ENGAUGE_ASSERT(cond) ((!(cond)) ? LoggerUpload::loggerAssert(#cond,__FILE__,__LINE__) : engauge_noop(cond))
15 
21 #define ENGAUGE_CHECK_PTR(ptr) (((ptr)==0) ? LoggerUpload::loggerCheckPtr(#ptr,__FILE__,__LINE__) : engauge_noop((ptr)==0))
22 
24 #endif // ENGAUGE_ASSERT_H