ble_mesh: stack: Update ARRAY_SIZE definition

pull/6275/head
lly 2020-12-04 11:42:15 +08:00
rodzic cee76786c4
commit 162e11cff3
1 zmienionych plików z 1 dodań i 3 usunięć

Wyświetl plik

@ -56,9 +56,7 @@ extern "C" {
* an array (e.g. pointer)
*/
#ifndef ARRAY_SIZE
#define ARRAY_SIZE(array) \
((unsigned long) (IS_ARRAY(array) + \
(sizeof(array) / sizeof((array)[0]))))
#define ARRAY_SIZE(array) (sizeof(array) / sizeof((array)[0]))
#endif
/* Evaluates to 1 if ptr is part of array, 0 otherwise; compile error if