stm8s/main.h

3 lines
76 B
C

// get length of array
#define ARRAY_LENGTH(x) (sizeof(x) / sizeof((x)[0]))