From 9885d98bf31261685e5caa20c065ee79ce95f170 Mon Sep 17 00:00:00 2001 From: Neargye Date: Fri, 31 Jan 2020 14:08:22 +0500 Subject: [PATCH] clean-up --- include/nameof.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/nameof.hpp b/include/nameof.hpp index 82ce6f5..e4887de 100644 --- a/include/nameof.hpp +++ b/include/nameof.hpp @@ -56,7 +56,7 @@ #endif // Checks nameof_enum compiler compatibility. -#if defined(__clang__) || defined(__GNUC__) && __GNUC__>= 9 || defined(_MSC_VER) +#if defined(__clang__) || defined(__GNUC__) && __GNUC__ >= 9 || defined(_MSC_VER) # undef NAMEOF_ENUM_SUPPORTED # define NAMEOF_ENUM_SUPPORTED 1 #endif @@ -367,7 +367,7 @@ template constexpr auto n() noexcept { static_assert(is_enum_v, "nameof::detail::n requires enum type."); #if defined(NAMEOF_ENUM_SUPPORTED) && NAMEOF_ENUM_SUPPORTED -# if defined(__clang__) || defined(__GNUC__) && __GNUC__>= 9 +# if defined(__clang__) || defined(__GNUC__) constexpr auto name = pretty_name({__PRETTY_FUNCTION__, sizeof(__PRETTY_FUNCTION__) - 2}); # elif defined(_MSC_VER) constexpr auto name = pretty_name({__FUNCSIG__, sizeof(__FUNCSIG__) - 17});