From 190d0645cc3b4244075c7d762b080ed67700690b Mon Sep 17 00:00:00 2001 From: Emil Ernerfeldt Date: Thu, 5 Apr 2018 13:31:27 +0200 Subject: [PATCH] replace __PRETTY_FUNCTION__ with __func__ for increased portability --- loguru.hpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/loguru.hpp b/loguru.hpp index bdb85963..2c949243 100644 --- a/loguru.hpp +++ b/loguru.hpp @@ -285,10 +285,6 @@ Website: www.ilikebigbits.com #define LOGURU_PREDICT_TRUE(x) (__builtin_expect(!!(x), 1)) #endif -#if defined(_MSC_VER) && !defined(__PRETTY_FUNCTION__) -#define __PRETTY_FUNCTION__ __FUNCTION__ -#endif - #if LOGURU_USE_FMTLIB #include #endif @@ -906,7 +902,7 @@ namespace loguru #define LOG_SCOPE_F(verbosity_name, ...) \ VLOG_SCOPE_F(loguru::Verbosity_ ## verbosity_name, __VA_ARGS__) -#define LOG_SCOPE_FUNCTION(verbosity_name) LOG_SCOPE_F(verbosity_name, __PRETTY_FUNCTION__) +#define LOG_SCOPE_FUNCTION(verbosity_name) LOG_SCOPE_F(verbosity_name, __func__) // ----------------------------------------------- // ABORT_F macro. Usage: ABORT_F("Cause of error: %s", error_str);