* gc.c (gc_mark_children): should NOT treat last element of
structs and arrays specially. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1809 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
a8c4400d1a
commit
a313c30d9c
@ -1,3 +1,8 @@
|
|||||||
|
Thu Nov 1 13:23:50 2001 Yukihiro Matsumoto <matz@ruby-lang.org>
|
||||||
|
|
||||||
|
* gc.c (gc_mark_children): should NOT treat last element of
|
||||||
|
structs and arrays specially.
|
||||||
|
|
||||||
Wed Oct 31 16:59:25 2001 Yukihiro Matsumoto <matz@ruby-lang.org>
|
Wed Oct 31 16:59:25 2001 Yukihiro Matsumoto <matz@ruby-lang.org>
|
||||||
|
|
||||||
* eval.c (exec_under): should initialize ruby_frame->self;
|
* eval.c (exec_under): should initialize ruby_frame->self;
|
||||||
|
12
gc.c
12
gc.c
@ -630,17 +630,13 @@ gc_mark_children(ptr)
|
|||||||
|
|
||||||
case T_ARRAY:
|
case T_ARRAY:
|
||||||
{
|
{
|
||||||
int i, len = obj->as.array.len - 1;
|
int i, len = obj->as.array.len;
|
||||||
VALUE *ptr = obj->as.array.ptr;
|
VALUE *ptr = obj->as.array.ptr;
|
||||||
|
|
||||||
for (i=0; i < len; i++) {
|
for (i=0; i < len; i++) {
|
||||||
PUSH_MARK(*ptr);
|
PUSH_MARK(*ptr);
|
||||||
ptr++;
|
ptr++;
|
||||||
}
|
}
|
||||||
if (len >= 0) {
|
|
||||||
obj = RANY(*ptr);
|
|
||||||
goto Again;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@ -698,17 +694,13 @@ gc_mark_children(ptr)
|
|||||||
|
|
||||||
case T_STRUCT:
|
case T_STRUCT:
|
||||||
{
|
{
|
||||||
int i, len = obj->as.rstruct.len - 1;
|
int i, len = obj->as.rstruct.len;
|
||||||
VALUE *ptr = obj->as.rstruct.ptr;
|
VALUE *ptr = obj->as.rstruct.ptr;
|
||||||
|
|
||||||
for (i=0; i < len; i++) {
|
for (i=0; i < len; i++) {
|
||||||
PUSH_MARK(*ptr);
|
PUSH_MARK(*ptr);
|
||||||
ptr++;
|
ptr++;
|
||||||
}
|
}
|
||||||
if (len >= 0) {
|
|
||||||
obj = RANY(ptr);
|
|
||||||
goto Again;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user