summaryrefslogtreecommitdiff
path: root/ace/OS.h
diff options
context:
space:
mode:
Diffstat (limited to 'ace/OS.h')
-rw-r--r--ace/OS.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/ace/OS.h b/ace/OS.h
index 393793e3a38..8b5c5342be5 100644
--- a/ace/OS.h
+++ b/ace/OS.h
@@ -153,6 +153,12 @@
// GreenHills C++ 1.8.8 complains that the (a) expression has no effect. But,
// it doesn't complain about unused args, so don't bother with them.
#define ACE_UNUSED_ARG(a)
+#elif defined (__GNUC__)
+// gcc 2.7.2 complains about unused args with -Wall, and complains
+// about "statement with no effect" with (a). This eliminates the
+// warnings, and no code is generated for the null conditional
+// statement.
+#define ACE_UNUSED_ARG(a) {if (&a) /* null */ ;}
#else
#define ACE_UNUSED_ARG(a) (a)
#endif /* ghs */