Using __attribute__((pure)) can conflict with a user-defined macro
"pure" - the correct form for system headers would use "__pure__"
instead. We have an existing macro that expands to this (with some
compiler variance handling too).

Signed-off-by: Martin Storsjö <[email protected]>
---
 mingw-w64-headers/crt/stdio.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/mingw-w64-headers/crt/stdio.h b/mingw-w64-headers/crt/stdio.h
index 12cfe2fee..4c67973b4 100644
--- a/mingw-w64-headers/crt/stdio.h
+++ b/mingw-w64-headers/crt/stdio.h
@@ -720,7 +720,7 @@ int vsnprintf (char *__stream, size_t __n, const char 
*__format, __builtin_va_li
   int __cdecl setvbuf(FILE * __restrict__ _File,char * __restrict__ _Buf,int 
_Mode,size_t _Size);
 #ifdef _UCRT
   __mingw_ovr
-  __attribute__((pure))
+  __MINGW_ATTRIB_PURE
   int __cdecl _scprintf(const char * __restrict__ _Format,...)
   {
     __builtin_va_list __ap;
@@ -741,7 +741,7 @@ int vsnprintf (char *__stream, size_t __n, const char 
*__format, __builtin_va_li
     return __ret;
   }
 #else
-  __attribute__((pure))
+  __MINGW_ATTRIB_PURE
   _CRTIMP int __cdecl _scprintf(const char * __restrict__ _Format,...);
   _CRTIMP int __cdecl _snscanf(const char * __restrict__ _Src,size_t 
_MaxCount,const char * __restrict__ _Format,...) 
__MINGW_ATTRIB_DEPRECATED_SEC_WARN;
 #endif
@@ -923,7 +923,7 @@ int vsprintf (char * __restrict__ __stream, const char * 
__restrict__ __format,
 #endif /* _UCRT */
 #endif /* __USE_MINGW_ANSI_STDIO */
 
-  __attribute__((pure))
+  __MINGW_ATTRIB_PURE
   _CRTIMP int __cdecl _vscprintf(const char * __restrict__ _Format,va_list 
_ArgList);
 
   _CRTIMP int __cdecl _set_printf_count_output(int _Value);
-- 
2.25.1



_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to