From e9663c859ebe94f75d0ff159c70c502f687e9011 Mon Sep 17 00:00:00 2001 From: Joyee Cheung Date: Fri, 24 May 2024 14:17:46 +0200 Subject: [PATCH] src: use __FUNCSIG__ on Windows in backtrace To show function signature if possible. --- src/util.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/util.h b/src/util.h index 7ac2b3efea3003..94c1851a591458 100644 --- a/src/util.h +++ b/src/util.h @@ -162,8 +162,12 @@ void DumpJavaScriptBacktrace(FILE* fp); #else #define LIKELY(expr) expr #define UNLIKELY(expr) expr +#if defined(_MSC_VER) +#define PRETTY_FUNCTION_NAME __FUNCSIG__ +#else #define PRETTY_FUNCTION_NAME "" #endif +#endif #define STRINGIFY_(x) #x #define STRINGIFY(x) STRINGIFY_(x)