common: Add support for compile time assertions.

(Allows us to check header lengths are sane)
master
Solomon Peachy 3 years ago
parent 3407c7ce22
commit a0ca92d25b
  1. 3
      backend_common.h

@ -109,6 +109,9 @@
/* To cheat the compiler */
#define UNUSED(expr) do { (void)(expr); } while (0)
/* Compile-time assertions */
#define STATIC_ASSERT(test_for_true) _Static_assert((test_for_true), "(" #test_for_true ") failed")
/* IEEE1284 ID processing */
struct deviceid_dict {
char *key;

Loading…
Cancel
Save