Only check __STDC_VERSION__ if __cplusplus is not defined

This commit is contained in:
embeddedt
2020-10-05 08:31:20 -04:00
committed by GitHub
parent 3dabec4cae
commit e557b0fbac

View File

@@ -18,7 +18,7 @@ extern "C" {
* DEFINES * DEFINES
*********************/ *********************/
#if __STDC_VERSION__ >= 199901L // If c99 or newer, use stdint.h to determine arch size #if defined(__cplusplus) || __STDC_VERSION__ >= 199901L // If c99 or newer, use stdint.h to determine arch size
#include <stdint.h> #include <stdint.h>
#endif #endif
@@ -53,7 +53,7 @@ typedef uint8_t lv_res_t;
#if __STDC_VERSION__ >= 199901L #if defined(__cplusplus) || __STDC_VERSION__ >= 199901L
// If c99 or newer, use the definition of uintptr_t directly from <stdint.h> // If c99 or newer, use the definition of uintptr_t directly from <stdint.h>
typedef uintptr_t lv_uintptr_t; typedef uintptr_t lv_uintptr_t;