From 66afd9b33ad955a7cfbd333b65ee4b5ba0ebbab2 Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Sat, 10 Feb 2018 05:16:16 -0800 Subject: [PATCH] Fix compilation on gcc 6 --- include/fmt/core.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/include/fmt/core.h b/include/fmt/core.h index ba14258b..7a566e78 100644 --- a/include/fmt/core.h +++ b/include/fmt/core.h @@ -147,7 +147,9 @@ (defined(_MSVC_LANG) && _MSVC_LANG > 201402L && _MSC_VER >= 1910) # include namespace fmt { using std::basic_string_view; } -#elif (FMT_HAS_INCLUDE() && __cplusplus >= 201402L) +// std::experimental::basic_string_view::remove_prefix isn't constexpr in gcc 6. +#elif (FMT_HAS_INCLUDE() && \ + __cplusplus >= 201402L && FMT_GCC_VERSION >= 700) # include namespace fmt { using std::experimental::basic_string_view; } #else