headers: Fix the order of asm() and attribute((deprecated())) in time.h

This fixes build errors with GCC, after
e5ac8c5509cd729b97065733cf4b0df0ec732797; GCC doesn't accept
__asm__(), expanded from __MINGW_ASM_CALL(), after
__attribute__((deprecated())), while Clang accepts both orders.

By default, __MINGW_ATTRIB_DEPRECATED_SEC_WARN doesn't expand
to anything, but if built with defines that makes this expand to
a deprecation attribute, the build would fail with GCC.

Signed-off-by: Martin Storsjö <martin@martin.st>
This commit is contained in:
Martin Storsjö 2024-06-05 10:42:15 +03:00
parent 921d142f8e
commit 386fc6b04a

View File

@ -214,9 +214,9 @@ extern "C" {
#if !defined (RC_INVOKED) && !defined (_INC_WTIME_INL)
#define _INC_WTIME_INL
#ifndef _USE_32BIT_TIME_T
wchar_t *__cdecl _wctime(const time_t *_Time) __MINGW_ATTRIB_DEPRECATED_SEC_WARN __MINGW_ASM_CALL(_wctime64);
wchar_t *__cdecl _wctime(const time_t *_Time) __MINGW_ASM_CALL(_wctime64) __MINGW_ATTRIB_DEPRECATED_SEC_WARN;
#else
wchar_t *__cdecl _wctime(const time_t *_Time) __MINGW_ATTRIB_DEPRECATED_SEC_WARN __MINGW_ASM_CALL(_wctime32);
wchar_t *__cdecl _wctime(const time_t *_Time) __MINGW_ASM_CALL(_wctime32) __MINGW_ATTRIB_DEPRECATED_SEC_WARN;
#endif
#endif