Check gcc version for diagnostic once.
This commit is contained in:
parent
16cb991fd8
commit
d49845510e
7
format.h
7
format.h
@ -56,12 +56,11 @@
|
||||
# define FMT_NOEXCEPT(expr)
|
||||
#endif
|
||||
|
||||
#ifdef __GNUC__
|
||||
#if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6)
|
||||
# define FMT_GCC_DIAGNOSTIC
|
||||
# pragma GCC diagnostic push
|
||||
# pragma GCC diagnostic ignored "-Wlong-long"
|
||||
#endif
|
||||
#endif
|
||||
|
||||
namespace fmt {
|
||||
|
||||
@ -1235,10 +1234,8 @@ inline Formatter<Write> Print(StringRef format) {
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef __GNUC__
|
||||
#if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6)
|
||||
#ifdef FMT_GCC_DIAGNOSTIC
|
||||
# pragma GCC diagnostic pop
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#endif // FORMAT_H_
|
||||
|
Loading…
Reference in New Issue
Block a user