tor  0.4.0.0-alpha-dev
Macros
ctassert.h File Reference
#include "lib/cc/compat_compiler.h"

Go to the source code of this file.

Macros

#define CTASSERT(x)   CTASSERT_EXPN((x), l, __LINE__)
 
#define CTASSERT_EXPN(x, a, b)   CTASSERT_DECL(x, a, b)
 
#define CTASSERT_DECL(x, a, b)   typedef char tor_ctassert_##a##_##b[(x) ? 1 : -1] ATTR_UNUSED
 

Detailed Description

Compile-time assertions: CTASSERT(expression).

Definition in file ctassert.h.

Macro Definition Documentation

◆ CTASSERT

#define CTASSERT (   x)    CTASSERT_EXPN((x), l, __LINE__)

CTASSERT(expression)

  Trigger a compiler error if expression is false.

Definition at line 44 of file ctassert.h.