summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-12-07 02:55:28 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-12-07 02:55:28 +0000
commit811efc8276e9ffd6adf95d8e954d8cac40ed49ef (patch)
treebb03cc131f9da2196a938b4021451f556d27b0da /ext
parent0bc733d9e3cf49c67b79a120ba08f1433ce82c7b (diff)
Add declaration of rb_warn
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38244 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext')
-rw-r--r--ext/refinement/refinement.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/ext/refinement/refinement.c b/ext/refinement/refinement.c
index 43ec2fb8b01..44ffd2a0b83 100644
--- a/ext/refinement/refinement.c
+++ b/ext/refinement/refinement.c
@@ -1,4 +1,11 @@
void ruby_Init_refinement(void);
+#ifdef __GNUC__
+#define PRINTF_ARGS(decl, string_index, first_to_check) \
+ decl __attribute__((format(printf, string_index, first_to_check)))
+#else
+#define PRINTF_ARGS(decl, string_index, first_to_check) decl
+#endif
+PRINTF_ARGS(void rb_warn(const char*, ...), 1, 2);
void
Init_refinement(void)