diff options
-rw-r--r-- | include/sys/debug.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/sys/debug.h b/include/sys/debug.h index cae2d49e4..a37740036 100644 --- a/include/sys/debug.h +++ b/include/sys/debug.h @@ -92,6 +92,8 @@ void spl_dumpstack(void); #define ASSERT3U(x,y,z) ((void)0) #define ASSERT3P(x,y,z) ((void)0) #define ASSERT0(x) ((void)0) +#define IMPLY(A, B) ((void)0) +#define EQUIV(A, B) ((void)0) /* * Debugging enabled (--enable-debug) @@ -105,6 +107,14 @@ void spl_dumpstack(void); #define ASSERT3U(x,y,z) VERIFY3U(x, y, z) #define ASSERT3P(x,y,z) VERIFY3P(x, y, z) #define ASSERT0(x) VERIFY0(x) +#define IMPLY(A, B) \ + ((void)(((!(A)) || (B)) || \ + spl_panic(__FILE__, __FUNCTION__, __LINE__, \ + "(" #A ") implies (" #B ")"))) +#define EQUIV(A, B) \ + ((void)((!!(A) == !!(B)) || \ + spl_panic(__FILE__, __FUNCTION__, __LINE__, \ + "(" #A ") is equivalent to (" #B ")"))) #endif /* NDEBUG */ |