From caa6db861768b6c1785111417169c081ba816edf Mon Sep 17 00:00:00 2001 From: Danila Malyutin Date: Mon, 27 Jul 2015 02:45:25 +0300 Subject: [PATCH] Replace clang diagnostics with gcc Clang understands both types of pragmas. Unfortunately it seems that due to bug in gcc (id=53431) this doesn't help --- Utilities/StrFmt.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Utilities/StrFmt.h b/Utilities/StrFmt.h index 3ee3e408f0..42fe597369 100644 --- a/Utilities/StrFmt.h +++ b/Utilities/StrFmt.h @@ -104,10 +104,10 @@ namespace fmt { std::vector buffptr(length); #if !defined(_MSC_VER) -#pragma clang diagnostic push -#pragma clang diagnostic ignored "-Wformat-security" +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wformat-security" size_t printlen = snprintf(buffptr.data(), length, fmt, std::forward(parameters)...); -#pragma clang diagnostic pop +#pragma GCC diagnostic pop #else size_t printlen = _snprintf_s(buffptr.data(), length, length - 1, fmt, std::forward(parameters)...); #endif