MCU-Common
Modules useful for embedded (MCU) programming
Common macros

Common macros. More...

Macros

#define VA_ARGC(...)
 Number of arguments for variadic macros (works for up to 16 arguments) More...
 
#define ARRAY_SIZE(x)   (sizeof(x)/sizeof(*(x)))
 Size of an array. More...
 

Detailed Description

Common macros.

Macro Definition Documentation

◆ VA_ARGC

#define VA_ARGC (   ...)
Value:
VA_ARGC_IMPL(__VA_ARGS__, 16, 15, 14, 13, 12, 11, 10, \
9, 8, 7, 6, 5, 4, 3, 2, 1, 0)
#define VA_ARGC_IMPL(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15, a16, n,...)
Definition: macros.h:40

Number of arguments for variadic macros (works for up to 16 arguments)

◆ ARRAY_SIZE

#define ARRAY_SIZE (   x)    (sizeof(x)/sizeof(*(x)))

Size of an array.