diff options
| author | Ingo Molnar <mingo@kernel.org> | 2023-10-07 11:32:24 +0200 |
|---|---|---|
| committer | Ingo Molnar <mingo@kernel.org> | 2023-10-07 11:32:24 +0200 |
| commit | 8db30574db25fa20cdcfa03e374edc3f8b8dc301 (patch) | |
| tree | 0b54686593694b68fb0537197eaa4bec7a44985d /include/uapi/linux/stddef.h | |
| parent | d4d6596b43868a1e05fe5b047e73c3aff96444c6 (diff) | |
| parent | 9e0bc36ab07c550d791bf17feeb479f1dfc42d89 (diff) | |
| download | lwn-8db30574db25fa20cdcfa03e374edc3f8b8dc301.tar.gz lwn-8db30574db25fa20cdcfa03e374edc3f8b8dc301.zip | |
Merge branch 'sched/urgent' into sched/core, to pick up fixes and refresh the branch
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'include/uapi/linux/stddef.h')
| -rw-r--r-- | include/uapi/linux/stddef.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/uapi/linux/stddef.h b/include/uapi/linux/stddef.h index 7c3fc3980881..5c6c4269f7ef 100644 --- a/include/uapi/linux/stddef.h +++ b/include/uapi/linux/stddef.h @@ -29,6 +29,11 @@ struct TAG { MEMBERS } ATTRS NAME; \ } +#ifdef __cplusplus +/* sizeof(struct{}) is 1 in C++, not 0, can't use C version of the macro. */ +#define __DECLARE_FLEX_ARRAY(T, member) \ + T member[0] +#else /** * __DECLARE_FLEX_ARRAY() - Declare a flexible array usable in a union * @@ -49,3 +54,5 @@ #ifndef __counted_by #define __counted_by(m) #endif + +#endif /* _UAPI_LINUX_STDDEF_H */ |
