update c23 warning
parent
983552657b
commit
29486df894
|
|
@ -24,11 +24,15 @@ extern "C" {
|
||||||
#pragma warning Unknown dynamic link import/export semantics.
|
#pragma warning Unknown dynamic link import/export semantics.
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef ICSNEO_BUILD_STATIC
|
||||||
|
#define ICSNEO_API
|
||||||
|
#else
|
||||||
#ifdef ICSNEO_EXPORTS
|
#ifdef ICSNEO_EXPORTS
|
||||||
#define ICSNEO_API EXPORT
|
#define ICSNEO_API EXPORT
|
||||||
#else
|
#else
|
||||||
#define ICSNEO_API IMPORT
|
#define ICSNEO_API IMPORT
|
||||||
#endif
|
#endif // ICSNEO_EXPORTS
|
||||||
|
#endif // ICSNEO_BUILD_STATIC
|
||||||
|
|
||||||
/** @brief icsneo_device_t opaque struct definition
|
/** @brief icsneo_device_t opaque struct definition
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -160,7 +160,7 @@ typedef uint32_t icsneo_devicetype_t;
|
||||||
|
|
||||||
// Make sure icsneo_devicetype_t is never smaller than the actual enum
|
// Make sure icsneo_devicetype_t is never smaller than the actual enum
|
||||||
#if __STDC_VERSION__ < 202311L && !defined(__cplusplus)
|
#if __STDC_VERSION__ < 202311L && !defined(__cplusplus)
|
||||||
_Static_assert(sizeof(_icsneo_devicetype_t) <= sizeof(icsneo_devicetype_t));
|
_Static_assert(sizeof(_icsneo_devicetype_t) <= sizeof(icsneo_devicetype_t), "icsneo_devicetype_t is too small");
|
||||||
#else // C++ or C23
|
#else // C++ or C23
|
||||||
static_assert(sizeof(_icsneo_devicetype_t) <= sizeof(icsneo_devicetype_t));
|
static_assert(sizeof(_icsneo_devicetype_t) <= sizeof(icsneo_devicetype_t));
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue