Skip to content

Commit 5bae026

Browse files
tritaosaghul
authored andcommitted
Workaround lack of C99 "static array bound" in cutils.h.
1 parent a75498b commit 5bae026

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cutils.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ extern "C" {
9898
#define container_of(ptr, type, member) ((type *)((uint8_t *)(ptr) - offsetof(type, member)))
9999
#endif
100100

101-
#if defined(_MSC_VER)
101+
#if defined(_MSC_VER) || defined(__cplusplus)
102102
#define minimum_length(n) n
103103
#else
104104
#define minimum_length(n) static n

0 commit comments

Comments
 (0)