summaryrefslogtreecommitdiff
path: root/ext/-test-
diff options
context:
space:
mode:
Diffstat (limited to 'ext/-test-')
-rw-r--r--ext/-test-/rational/rat.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/ext/-test-/rational/rat.c b/ext/-test-/rational/rat.c
index 0138834..b1ffbda 100644
--- a/ext/-test-/rational/rat.c
+++ b/ext/-test-/rational/rat.c
@@ -29,9 +29,17 @@ gcd_gmp(VALUE x, VALUE y)
#define gcd_gmp rb_f_notimplement
#endif
+static VALUE
+s_rational_raw(VALUE klass, VALUE x, VALUE y)
+{
+ return rb_rational_raw(x, y);
+}
+
void
Init_rational(VALUE klass)
{
rb_define_method(rb_cInteger, "gcd_normal", gcd_normal, 1);
rb_define_method(rb_cInteger, "gcd_gmp", gcd_gmp, 1);
+
+ rb_define_singleton_method(rb_cRational, "raw", s_rational_raw, 2);
}