From 981797f0597f74aa9739979a98357275e5ae16fc Mon Sep 17 00:00:00 2001 From: medithe <40990424+medithe@users.noreply.github.com> Date: Fri, 7 Sep 2018 17:53:15 +0200 Subject: [PATCH] Get rid of implicit-fallthrough warn. in GCC 7 and 8 This change enables FMT_FALLLTHROUGH also for GCC-Compilers in the versions 7 and 8. --- include/fmt/format-inl.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/fmt/format-inl.h b/include/fmt/format-inl.h index c9c0a6dae126..38d561e17629 100644 --- a/include/fmt/format-inl.h +++ b/include/fmt/format-inl.h @@ -630,6 +630,8 @@ FMT_FUNC void grisu2_prettify(char *buffer, size_t &size, int exp, #if FMT_CLANG_VERSION # define FMT_FALLTHROUGH [[clang::fallthrough]]; +#elif FMT_GCC_VERSION >= 700 +# define FMT_FALLTHROUGH [[gnu::fallthrough]]; #else # define FMT_FALLTHROUGH #endif