diff options
author | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2004-10-18 06:59:41 +0000 |
---|---|---|
committer | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2004-10-18 06:59:41 +0000 |
commit | da155576adf92e32898fa6b545a3f85009f904b9 (patch) | |
tree | 875486754b6859acc4ca221e7ad9143e2937654b | |
parent | f4e88fb23a0da8c3afea4e437db34626be4578a5 (diff) | |
download | ruby-da155576adf92e32898fa6b545a3f85009f904b9.tar.gz |
* range.c (range_step, range_each): need cast.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@7061 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | range.c | 6 |
2 files changed, 8 insertions, 2 deletions
@@ -1,3 +1,7 @@ +Mon Oct 18 15:58:01 2004 NAKAMURA Usaku <usa@ruby-lang.org> + + * range.c (range_step, range_each): need cast. + Mon Oct 18 07:26:21 2004 Nobuyoshi Nakada <nobu@ruby-lang.org> * file.c (rb_file_truncate): discard read buffer before truncation. @@ -338,7 +338,8 @@ range_step(argc, argv, range) if (unit == 0) rb_raise(rb_eArgError, "step can't be 0"); args[0] = b; args[1] = e; args[2] = range; iter[0] = 1; iter[1] = unit; - rb_iterate(str_step, (VALUE)args, step_i, (VALUE)iter); + rb_iterate((VALUE(*)_((VALUE)))str_step, (VALUE)args, step_i, + (VALUE)iter); } else if (rb_obj_is_kind_of(b, rb_cNumeric)) { ID c = rb_intern(EXCL(range) ? "<" : "<="); @@ -421,7 +422,8 @@ range_each(range) args[0] = beg; args[1] = end; args[2] = range; iter[0] = 1; iter[1] = 1; - rb_iterate(str_step, (VALUE)args, step_i, (VALUE)iter); + rb_iterate((VALUE(*)_((VALUE)))str_step, (VALUE)args, step_i, + (VALUE)iter); } else { range_each_func(range, each_i, beg, end, NULL); |