From f13b6786f0aefd2060ca976f7e42db7387b49450 Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Fri, 18 Jan 2019 14:53:54 -0500 Subject: [PATCH] [pragma] Only add if GCC or clang --- src/hb.hh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/hb.hh b/src/hb.hh index c0ad83925..c71375516 100644 --- a/src/hb.hh +++ b/src/hb.hh @@ -30,6 +30,7 @@ #define HB_HH #ifndef HB_NO_DIAGNOSTIC_PRAGMAS +#if defined(__GNUC__) || defined(__clang__) /* Rules: * * - All pragmas are declared GCC even if they are clang ones. Otherwise GCC @@ -102,6 +103,8 @@ #pragma GCC diagnostic ignored "-Wpacked" // Erratic impl in clang #pragma GCC diagnostic ignored "-Wstrict-aliasing" #pragma GCC diagnostic ignored "-Wtype-limits" + +#endif #endif #ifdef HAVE_CONFIG_H