https://git.reactos.org/?p=reactos.git;a=commitdiff;h=51e6ce3aa7c880709f8f29483d8df85c22c560ca
commit 51e6ce3aa7c880709f8f29483d8df85c22c560ca Author: Timo Kreuzer <timo.kreu...@reactos.org> AuthorDate: Sun Oct 13 10:55:31 2024 +0300 Commit: Timo Kreuzer <timo.kreu...@reactos.org> CommitDate: Thu Jan 16 14:18:53 2025 +0200 [UCRT] Add GCC compatible __FUNCTIONW__ --- sdk/include/ucrt/corecrt.h | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/sdk/include/ucrt/corecrt.h b/sdk/include/ucrt/corecrt.h index b89f0a94c22..4fe20566df9 100644 --- a/sdk/include/ucrt/corecrt.h +++ b/sdk/include/ucrt/corecrt.h @@ -280,7 +280,18 @@ extern "C++" #define _CRT_SIZE_MAX ((size_t)-1) #define __FILEW__ _CRT_WIDE(__FILE__) + +#ifdef _MSC_VER #define __FUNCTIONW__ _CRT_WIDE(__FUNCTION__) +#else // _MSC_VER +#define __FUNCTIONW__ \ +({ \ + static wchar_t __funcw__[sizeof(__func__)]; \ + for (size_t i = 0; i < sizeof(__func__); i++) \ + __funcw__[i] = __func__[i]; \ + __funcw__; \ +}) +#endif // _MSC_VER #ifdef __cplusplus #ifndef _STATIC_ASSERT