2010-07-21  Ozkan Sezer  <sezeroz@gmail.com>

	* _mingw.h (__MINGW_ATTRIB_UNUSED): Define as __attribute__((unused))
	for gcc.
	(__MINGW_ATTRIB_USED): Define as __attribute__((used)) for gcc, or as
	__MINGW_ATTRIB_UNUSED where it is not supported ie. gcc < 3.1 or !gcc.


git-svn-id: svn+ssh://svn.code.sf.net/p/mingw-w64/code/trunk@2914 4407c894-4637-0410-b4f5-ada5f102cad1
diff --git a/mingw-w64-headers/crt/ChangeLog b/mingw-w64-headers/crt/ChangeLog
index 931ca5c..9c1dddc 100644
--- a/mingw-w64-headers/crt/ChangeLog
+++ b/mingw-w64-headers/crt/ChangeLog
@@ -1,3 +1,10 @@
+2010-07-21  Ozkan Sezer  <sezeroz@gmail.com>
+
+	* _mingw.h (__MINGW_ATTRIB_UNUSED): Define as __attribute__((unused))
+	for gcc.
+	(__MINGW_ATTRIB_USED): Define as __attribute__((used)) for gcc, or as
+	__MINGW_ATTRIB_UNUSED where it is not supported ie. gcc < 3.1 or !gcc.
+
 2010-07-18  Ozkan Sezer  <sezeroz@gmail.com>
 
 	* assert.h (assert): Check against both _UNICODE and UNICODE.
diff --git a/mingw-w64-headers/crt/_mingw.h b/mingw-w64-headers/crt/_mingw.h
index 03fef15..42f1285 100644
--- a/mingw-w64-headers/crt/_mingw.h
+++ b/mingw-w64-headers/crt/_mingw.h
@@ -114,9 +114,17 @@
 #define __MINGW_ATTRIB_NONNULL(arg)
 #endif /* GNUC >= 3.3 */
 
+#ifdef __GNUC__
+#define __MINGW_ATTRIB_UNUSED __attribute__ ((__unused__))
+#else
+#define __MINGW_ATTRIB_UNUSED
+#endif /* ATTRIBUTE_UNUSED */
+
 #if  __MINGW_GNUC_PREREQ (3, 1)
+#define __MINGW_ATTRIB_USED __attribute__ ((__used__))
 #define __MINGW_ATTRIB_DEPRECATED __attribute__ ((__deprecated__))
 #else
+#define __MINGW_ATTRIB_USED __MINGW_ATTRIB_UNUSED
 #define __MINGW_ATTRIB_DEPRECATED
 #endif /* GNUC >= 3.1 */