aboutsummaryrefslogtreecommitdiffstats
path: root/numeric.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-09-07 19:04:28 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-09-07 19:04:28 +0000
commitba6c7348472f936e852285b11f71e858d2ed4f35 (patch)
treee709e5482cf05035851dfeb83a4348c99ac28275 /numeric.c
parent622a2af0ba13f71c4d9adac1efa97b3aa63bce76 (diff)
downloadruby-ba6c7348472f936e852285b11f71e858d2ed4f35.tar.gz
numeric.c: no extra checks
* numeric.c (NUM_STEP_SCAN_ARGS): remove extra class checks, which cause the incompatibilities. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42876 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'numeric.c')
-rw-r--r--numeric.c10
1 files changed, 0 insertions, 10 deletions
diff --git a/numeric.c b/numeric.c
index c67b97ee55..9bbce09e64 100644
--- a/numeric.c
+++ b/numeric.c
@@ -1864,20 +1864,10 @@ ruby_num_interval_step_size(VALUE from, VALUE to, VALUE step, int excl)
if (NIL_P(step)) { \
step = INT2FIX(1); \
} \
- else { \
- if (!rb_obj_is_kind_of(step, rb_cNumeric)) { \
- rb_raise(rb_eTypeError, "step must be numeric"); \
- } \
- } \
desc = negative_int_p(step); \
if (NIL_P(to)) { \
to = desc ? DBL2NUM(-INFINITY) : DBL2NUM(INFINITY); \
} \
- else { \
- if (!rb_obj_is_kind_of(to, rb_cNumeric)) { \
- rb_raise(rb_eTypeError, "limit must be numeric"); \
- } \
- } \
} while (0)
#define NUM_STEP_GET_INF(to, desc, inf) do { \