headers/string: Include <corecrt_memory.h> to deduplicate declarations Signed-off-by: LIU Hao <lh_mouse@126.com>
diff --git a/mingw-w64-headers/crt/string.h b/mingw-w64-headers/crt/string.h index 34bb336..d8382fa 100644 --- a/mingw-w64-headers/crt/string.h +++ b/mingw-w64-headers/crt/string.h
@@ -7,15 +7,7 @@ #define _INC_STRING #include <crtdefs.h> - -#if defined(__LIBMSVCRT__) -/* When building mingw-w64, this should be blank. */ -#define _SECIMP -#else -#ifndef _SECIMP -#define _SECIMP __declspec(dllimport) -#endif /* _SECIMP */ -#endif /* defined(__LIBMSVCRT__) */ +#include <corecrt_memory.h> #ifdef __cplusplus extern "C" { @@ -38,30 +30,6 @@ #endif #endif -#define _WConst_return _CONST_RETURN - -#ifndef _CRT_MEMORY_DEFINED -#define _CRT_MEMORY_DEFINED - _CRTIMP void *__cdecl _memccpy(void *_Dst,const void *_Src,int _Val,size_t _MaxCount); -#if !defined(__STRICT_ANSI__) || defined(_GNU_SOURCE) || __STDC_VERSION__ + 0 >= 202311L || _XOPEN_SOURCE + 0 >= 600 - void * __cdecl memccpy(void *_Dst,const void *_Src,int _Val,size_t _Size); -#endif - _CONST_RETURN void *__cdecl memchr(const void *_Buf ,int _Val,size_t _MaxCount); - _CRTIMP int __cdecl _memicmp(const void *_Buf1,const void *_Buf2,size_t _Size); - _CRTIMP int __cdecl _memicmp_l(const void *_Buf1,const void *_Buf2,size_t _Size,_locale_t _Locale); - int __cdecl memcmp(const void *_Buf1,const void *_Buf2,size_t _Size); - void * __cdecl memcpy(void * __restrict__ _Dst,const void * __restrict__ _Src,size_t _Size) __MINGW_ATTRIB_DEPRECATED_SEC_WARN; - _SECIMP errno_t __cdecl memcpy_s (void *_dest,size_t _numberOfElements,const void *_src,size_t _count); - void * __cdecl mempcpy (void *_Dst, const void *_Src, size_t _Size); - void * __cdecl memset(void *_Dst,int _Val,size_t _Size); -#if !defined(__STRICT_ANSI__) || __STDC_VERSION__ + 0 >= 202311L - void * __cdecl memset_explicit(void *_Dst,int _Val,size_t _Size); -#endif -#ifndef NO_OLDNAMES - void * __cdecl memccpy(void *_Dst,const void *_Src,int _Val,size_t _Size) __MINGW_ATTRIB_DEPRECATED_MSVC2005; - int __cdecl memicmp(const void *_Buf1,const void *_Buf2,size_t _Size) __MINGW_ATTRIB_DEPRECATED_MSVC2005; -#endif -#endif char * __cdecl _strset(char *_Str,int _Val) __MINGW_ATTRIB_DEPRECATED_SEC_WARN; char * __cdecl _strset_l(char *_Str,int _Val,_locale_t _Locale) __MINGW_ATTRIB_DEPRECATED_SEC_WARN; char * __cdecl strcpy(char * __restrict__ _Dest,const char * __restrict__ _Source);