This redefining of the macro was added in
824ceb1d1265e257d8b85d8e191f4db2a1e7735c, without an explanation
of why that was done.

If we really do need to use a different inline declaration for
these functions, we should use a different macro, so we don't
alter the meaning of the __mingw_ovr define after including
swprintf.inl or wchar.h.

This practically has the effect, that these inlines are declared
as regular "inline" instead of "static __inline__" when built
in C++ mode with a GCC compatible compiler. This matches how
the __mingw_ovr macro is defined and used for many other inline
functions.

Signed-off-by: Martin Storsjö <mar...@martin.st>
---
 mingw-w64-headers/crt/swprintf.inl | 13 -------------
 mingw-w64-headers/crt/wchar.h      | 13 -------------
 2 files changed, 26 deletions(-)

diff --git a/mingw-w64-headers/crt/swprintf.inl 
b/mingw-w64-headers/crt/swprintf.inl
index 0d4904bcd..d990d428c 100644
--- a/mingw-w64-headers/crt/swprintf.inl
+++ b/mingw-w64-headers/crt/swprintf.inl
@@ -9,19 +9,6 @@
 
 #include <vadefs.h>
 
-#undef __mingw_ovr
-#if defined (__GNUC__)
-#define __mingw_ovr static __attribute__ ((__unused__)) __inline__ __cdecl
-#ifdef __mingw_static_ovr
-#undef __mingw_static_ovr
-#define __mingw_static_ovr __mingw_ovr
-#endif
-#elif defined(__cplusplus)
-#define __mingw_ovr inline __cdecl
-#else
-#define __mingw_ovr static __cdecl
-#endif
-
 __mingw_ovr
 /* __attribute__((__format__ (gnu_wprintf, 3, 0))) */ __MINGW_ATTRIB_NONNULL(3)
 int vswprintf (wchar_t *__stream, size_t __count, const wchar_t *__format, 
__builtin_va_list __local_argv)
diff --git a/mingw-w64-headers/crt/wchar.h b/mingw-w64-headers/crt/wchar.h
index 6d3b537c2..b1c103686 100644
--- a/mingw-w64-headers/crt/wchar.h
+++ b/mingw-w64-headers/crt/wchar.h
@@ -520,19 +520,6 @@ extern FILE (* __MINGW_IMP_SYMBOL(_iob))[];        /* A 
pointer to an array of FILE */
   int __cdecl __stdio_common_vfwscanf(unsigned __int64 options, FILE *file, 
const wchar_t *format, _locale_t locale, va_list valist);
 #endif
 
-#undef __mingw_ovr
-#if defined (__GNUC__)
-#define __mingw_ovr static __attribute__ ((__unused__)) __inline__ __cdecl
-#ifdef __mingw_static_ovr
-#undef __mingw_static_ovr
-#define __mingw_static_ovr __mingw_ovr
-#endif
-#elif defined(__cplusplus)
-#define __mingw_ovr inline __cdecl
-#else
-#define __mingw_ovr static __cdecl
-#endif
-
 #if __USE_MINGW_ANSI_STDIO
 
 /*
-- 
2.34.1



_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to