mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* array.c: fixed types.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23323 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
f7b562ef01
commit
1f6f4e6b59
2 changed files with 6 additions and 6 deletions
8
array.c
8
array.c
|
@ -45,10 +45,10 @@ memfill(register VALUE *mem, register long size, register VALUE val)
|
|||
|
||||
# define ARY_SHARED_P(ary) \
|
||||
(assert(!FL_TEST(ary, ELTS_SHARED) || !FL_TEST(ary, RARRAY_EMBED_FLAG)), \
|
||||
FL_TEST(ary,ELTS_SHARED))
|
||||
FL_TEST(ary,ELTS_SHARED)!=0)
|
||||
# define ARY_EMBED_P(ary) \
|
||||
(assert(!FL_TEST(ary, ELTS_SHARED) || !FL_TEST(ary, RARRAY_EMBED_FLAG)), \
|
||||
FL_TEST(ary, RARRAY_EMBED_FLAG))
|
||||
FL_TEST(ary, RARRAY_EMBED_FLAG)!=0)
|
||||
|
||||
#define ARY_HEAP_PTR(a) (assert(!ARY_EMBED_P(a)), RARRAY(a)->as.heap.ptr)
|
||||
#define ARY_HEAP_LEN(a) (assert(!ARY_EMBED_P(a)), RARRAY(a)->as.heap.len)
|
||||
|
@ -192,7 +192,7 @@ static void
|
|||
rb_ary_decrement_share(VALUE shared)
|
||||
{
|
||||
if (shared) {
|
||||
int num = ARY_SHARED_NUM(shared) - 1;
|
||||
long num = ARY_SHARED_NUM(shared) - 1;
|
||||
if (num == 0) {
|
||||
rb_ary_free(shared);
|
||||
rb_gc_force_recycle(shared);
|
||||
|
@ -222,7 +222,7 @@ rb_ary_unshare_safe(VALUE ary)
|
|||
static VALUE
|
||||
rb_ary_increment_share(VALUE shared)
|
||||
{
|
||||
int num = ARY_SHARED_NUM(shared);
|
||||
long num = ARY_SHARED_NUM(shared);
|
||||
if (num >= 0) {
|
||||
ARY_SET_SHARED_NUM(shared, num + 1);
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#define RUBY_VERSION "1.9.2"
|
||||
#define RUBY_RELEASE_DATE "2009-05-01"
|
||||
#define RUBY_RELEASE_DATE "2009-05-02"
|
||||
#define RUBY_PATCHLEVEL -1
|
||||
#define RUBY_BRANCH_NAME "trunk"
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
|||
#define RUBY_VERSION_TEENY 1
|
||||
#define RUBY_RELEASE_YEAR 2009
|
||||
#define RUBY_RELEASE_MONTH 5
|
||||
#define RUBY_RELEASE_DAY 1
|
||||
#define RUBY_RELEASE_DAY 2
|
||||
|
||||
#ifdef RUBY_EXTERN
|
||||
RUBY_EXTERN const char ruby_version[];
|
||||
|
|
Loading…
Reference in a new issue