summaryrefslogtreecommitdiff
path: root/numeric.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1998-02-13 09:40:29 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1998-02-13 09:40:29 +0000
commit1b7f82e62577986a6122ef453323ace74980d91e (patch)
tree3518499de338e8c28ec5daaa1396b381e9676e66 /numeric.c
parent00080ffcbb05cf23bce8e31f0538567f5b780f89 (diff)
\s and assignment in conditional
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/v1_1r@72 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'numeric.c')
-rw-r--r--numeric.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/numeric.c b/numeric.c
index 61e695a605..f924761001 100644
--- a/numeric.c
+++ b/numeric.c
@@ -49,7 +49,7 @@ coerce_body(x)
coerce_rescue(x)
VALUE *x;
{
- TypeError("%s can't convert into %s",
+ TypeError("%s can't be coerced into %s",
rb_class2name(CLASS_OF(x[1])),
rb_class2name(CLASS_OF(x[0])));
}
@@ -59,14 +59,10 @@ do_coerce(x, y)
VALUE *x, *y;
{
VALUE ary;
-#if 0
VALUE a[2];
a[0] = *x; a[1] = *y;
ary = rb_rescue(coerce_body, a, coerce_rescue, a);
-#else
- ary = rb_funcall(*y, coerce, 1, *x);
-#endif
if (TYPE(ary) != T_ARRAY || RARRAY(ary)->len != 2) {
TypeError("coerce must return [x, y]");
}