aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-05-24 08:18:47 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-05-24 08:18:47 +0000
commit55896408045ea9b15a215d369752ab784db79dbe (patch)
tree10372172fd7397610af5b9c1fb93c1faa0f08d53 /include
parent0ed74fa766fc9675ce59f74117ffd448290d2cfd (diff)
downloadruby-55896408045ea9b15a215d369752ab784db79dbe.tar.gz
defines.h: fallback ERRORFUNC and WARNINGFUNC
* include/ruby/defines.h (ERRORFUNC, WARNINGFUNC): add fallback definitions. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55143 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'include')
-rw-r--r--include/ruby/defines.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/include/ruby/defines.h b/include/ruby/defines.h
index 49127e0106..25700165d0 100644
--- a/include/ruby/defines.h
+++ b/include/ruby/defines.h
@@ -45,6 +45,18 @@ extern "C" {
#ifndef NOINLINE
# define NOINLINE(x) x
#endif
+#ifndef ERRORFUNC
+# define HAVE_ATTRIBUTE_ERRORFUNC 0
+# define ERRORFUNC(mesg, x) x
+#else
+# define HAVE_ATTRIBUTE_ERRORFUNC 1
+#endif
+#ifndef WARNINGFUNC
+# define HAVE_ATTRIBUTE_WARNINGFUNC 0
+# define WARNINGFUNC(mesg, x) x
+#else
+# define HAVE_ATTRIBUTE_WARNINGFUNC 1
+#endif
#ifndef GCC_VERSION_SINCE
#define GCC_VERSION_SINCE(major, minor, patchlevel) \