From 9b6ee42d860497dcbf4e46facbfdfb1e0fe6ee23 Mon Sep 17 00:00:00 2001 From: nobu Date: Sat, 7 Sep 2013 19:04:33 +0000 Subject: numeric.c: use positive_int_p * numeric.c (NUM_STEP_SCAN_ARGS): use positive_int_p() to fix rubyspec failures. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42877 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- numeric.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'numeric.c') diff --git a/numeric.c b/numeric.c index 9bbce09e64..2ce1d51c92 100644 --- a/numeric.c +++ b/numeric.c @@ -1864,7 +1864,7 @@ ruby_num_interval_step_size(VALUE from, VALUE to, VALUE step, int excl) if (NIL_P(step)) { \ step = INT2FIX(1); \ } \ - desc = negative_int_p(step); \ + desc = !positive_int_p(step); \ if (NIL_P(to)) { \ to = desc ? DBL2NUM(-INFINITY) : DBL2NUM(INFINITY); \ } \ -- cgit v1.2.3