[ruby/json] Suppress -Wunknown-pragmas warnings

97f47d1cfd
This commit is contained in:
Nobuyoshi Nakada 2025-04-07 19:44:45 +09:00 committed by Hiroshi SHIBATA
parent d5f94941d8
commit b1362e26c7

View file

@ -35,11 +35,13 @@ SOFTWARE.
typedef uint_fast32_t u32_t;
typedef uint_fast64_t u64_t;
#if defined __clang__
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wshorten-64-to-32"
#elif defined __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wmissing-braces"
#endif
#define u32(x) ((u32_t)(x))
#define u64(x) ((u64_t)(x))
@ -270,8 +272,10 @@ jeaiii_ultoa(char *b, u64_t n)
#undef u64
#undef COPY
#if defined __clang__
#pragma clang diagnostic pop
#elif defined __GNUC__
#pragma GCC diagnostic pop
#endif
#endif // JEAIII_TO_TEXT_H_