aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2015-08-03 11:40:22 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2015-08-03 11:40:22 +0200
commit9bf4ff12e6d96870fa48785846de5c96411ec5ea (patch)
tree98cc74f53feb6dbb585f99de20383b6e07d2c964
parent8138a68a75286eebc04557019ab0f5947d78eb99 (diff)
Make UNUSED macro work for xlC
-rw-r--r--odb/details/unused.hxx6
1 files changed, 3 insertions, 3 deletions
diff --git a/odb/details/unused.hxx b/odb/details/unused.hxx
index 8d3af30..56d7244 100644
--- a/odb/details/unused.hxx
+++ b/odb/details/unused.hxx
@@ -7,11 +7,11 @@
#include <odb/pre.hxx>
-// VC++ doesn't like the (void)x expression if x is a reference to
-// an incomplete type. On the other hand, GCC warns that (void*)&x
+// VC++ and xlC don't like the (void)x expression if x is a reference
+// to an incomplete type. On the other hand, GCC warns that (void*)&x
// doesn't have any effect.
//
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__xlC__)
# define ODB_POTENTIALLY_UNUSED(x) (void*)&x
#else
# define ODB_POTENTIALLY_UNUSED(x) (void)x