summaryrefslogtreecommitdiff
path: root/include/ruby/ruby.h
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2020-01-09 19:08:54 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2020-01-09 21:32:26 +0900
commit661e07c97e1cc742290d045dc5102e5fbdbae6a1 (patch)
tree9e05f167f642e1843a631dc9e6bd437642945d98 /include/ruby/ruby.h
parent23fbee0311d34da4f623a828bf0c015a90d8edc9 (diff)
Moved the definition of `rb_define_method_if_constexpr`
Inside the block where `RB_METHOD_DEFINITION_DECL` family are defined.
Diffstat (limited to 'include/ruby/ruby.h')
-rw-r--r--include/ruby/ruby.h1
1 files changed, 0 insertions, 1 deletions
diff --git a/include/ruby/ruby.h b/include/ruby/ruby.h
index 625636fcdc..ada86dab95 100644
--- a/include/ruby/ruby.h
+++ b/include/ruby/ruby.h
@@ -2703,7 +2703,6 @@ RB_METHOD_DEFINITION_DECL(rb_define_method, (2,3), (VALUE klass, const char *nam
#ifdef __cplusplus
#define rb_define_method(m, n, f, a) rb_define_method_tmpl<a>::define(m, n, f)
#else
-#define rb_define_method_if_constexpr(x, t, f) __builtin_choose_expr(__builtin_choose_expr(__builtin_constant_p(x),(x),0),(t),(f))
#define rb_define_method_choose_prototype15(n) rb_define_method_if_constexpr((n)==15,rb_define_method15,rb_define_methodm3)
#define rb_define_method_choose_prototype14(n) rb_define_method_if_constexpr((n)==14,rb_define_method14,rb_define_method_choose_prototype15(n))
#define rb_define_method_choose_prototype13(n) rb_define_method_if_constexpr((n)==13,rb_define_method13,rb_define_method_choose_prototype14(n))