toolchain: Add flag indicating zero length array support
Add flag which indicates if a toolchain supports ZLA (Zero Length Arrays). It is a GCCC extension inherited by clang as well. Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
This commit is contained in:
parent
c6fd21c5de
commit
1e7b540aa8
|
@ -115,6 +115,14 @@
|
|||
#define TOOLCHAIN_HAS_C_AUTO_TYPE 0
|
||||
#endif
|
||||
|
||||
/**
|
||||
* @def TOOLCHAIN_HAS_ZLA
|
||||
* @brief Indicate if toolchain supports Zero Length Arrays.
|
||||
*/
|
||||
#ifndef TOOLCHAIN_HAS_ZLA
|
||||
#define TOOLCHAIN_HAS_ZLA 0
|
||||
#endif
|
||||
|
||||
/**
|
||||
* @def TOOLCHAIN_IGNORE_WSHADOW_BEGIN
|
||||
* @brief Begin of block to ignore -Wshadow.
|
||||
|
|
|
@ -30,6 +30,8 @@
|
|||
#define TOOLCHAIN_HAS_C_AUTO_TYPE 1
|
||||
#endif
|
||||
|
||||
#define TOOLCHAIN_HAS_ZLA 1
|
||||
|
||||
/*
|
||||
* Older versions of GCC do not define __BYTE_ORDER__, so it must be manually
|
||||
* detected and defined using arch-specific definitions.
|
||||
|
|
Loading…
Reference in New Issue