summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog9
-rw-r--r--internal.h8
2 files changed, 17 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 5674772bee..ed404cddde 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+Fri Sep 16 21:28:25 2016 Naohisa Goto <ngotogenome@gmail.com>
+
+ * internal.h (MAYBE_UNUSED): The fallback definition is needed.
+ Fix compile error with some non-GCC compilers such as
+ Oracle Solaris Studio 12.3 on Solaris 10.
+ [Bug #12767] [ruby-dev:49807]
+
+ * internal.h (WARN_UNUSED_RESULT): ditto.
+
Fri Sep 16 21:19:51 2016 Naohisa Goto <ngotogenome@gmail.com>
* hash.c (each_pair_i_fast): Fix compile error with old version of
diff --git a/internal.h b/internal.h
index 57d023600a..54e5d3bc78 100644
--- a/internal.h
+++ b/internal.h
@@ -26,6 +26,14 @@ extern "C" {
#define LIKELY(x) RB_LIKELY(x)
#define UNLIKELY(x) RB_UNLIKELY(x)
+#ifndef MAYBE_UNUSED
+# define MAYBE_UNUSED(x) x
+#endif
+
+#ifndef WARN_UNUSED_RESULT
+# define WARN_UNUSED_RESULT(x) x
+#endif
+
#ifdef HAVE_VALGRIND_MEMCHECK_H
# include <valgrind/memcheck.h>
# ifndef VALGRIND_MAKE_MEM_DEFINED