1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-01-17 05:32:45 +01:00

Merge pull request #18016 from maribu/core/xfa

core/xfa: Silence clangd warning
This commit is contained in:
benpicco 2022-04-28 11:26:17 +02:00 committed by GitHub
commit 97a81f7461
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -25,6 +25,8 @@
#ifndef XFA_H
#define XFA_H
#include <inttypes.h>
/*
* Unfortunately, current gcc trips over accessing XFA's because of their
* zero-size start/end array that are used of symbol markers, with an "array
@ -177,7 +179,7 @@ _Pragma("GCC diagnostic ignored \"-Warray-bounds\"")
* @brief Calculate number of entries in cross-file array
*/
#define XFA_LEN(type, \
name) (((const char *)name ## _end - (const char *)name) / \
name) (((uintptr_t)name ## _end - (uintptr_t)name) / \
sizeof(type))
#ifdef __cplusplus