summaryrefslogtreecommitdiff
path: root/rational.c
diff options
context:
space:
mode:
Diffstat (limited to 'rational.c')
-rw-r--r--rational.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/rational.c b/rational.c
index de5c7867c3..2cfe9288be 100644
--- a/rational.c
+++ b/rational.c
@@ -777,13 +777,9 @@ nurat_mul(VALUE self, VALUE other)
}
}
-#define id_to_r rb_intern("to_r")
-#define f_to_r(x) rb_funcall(x, id_to_r, 0)
-
static VALUE
nurat_div(VALUE self, VALUE other)
{
- again:
switch (TYPE(other)) {
case T_FIXNUM:
case T_BIGNUM:
@@ -1407,6 +1403,9 @@ string_to_r(VALUE self)
return rb_rational_new1(INT2FIX(0));
}
+#define id_to_r rb_intern("to_r")
+#define f_to_r(x) rb_funcall(x, id_to_r, 0)
+
static VALUE
nurat_s_convert(int argc, VALUE *argv, VALUE klass)
{