projects
/
model-checker.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
model: add deadlock detection
[model-checker.git]
/
common.h
diff --git
a/common.h
b/common.h
index 50410ea7e0a1bce920a2bb3ce3b968d602f929de..81b26728d917c0af8c1b26e9d0fa2d28cccb8a5a 100644
(file)
--- a/
common.h
+++ b/
common.h
@@
-20,6
+20,7
@@
void assert_hook(void);
void assert_hook(void);
+#ifdef CONFIG_ASSERT
#define ASSERT(expr) \
do { \
if (!(expr)) { \
#define ASSERT(expr) \
do { \
if (!(expr)) { \
@@
-30,6
+31,10
@@
do { \
exit(EXIT_FAILURE); \
} \
} while (0)
exit(EXIT_FAILURE); \
} \
} while (0)
+#else
+#define ASSERT(expr) \
+ do { } while (0)
+#endif /* CONFIG_ASSERT */
#define error_msg(...) fprintf(stderr, "Error: " __VA_ARGS__)
#define error_msg(...) fprintf(stderr, "Error: " __VA_ARGS__)