mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* eval.c (rb_mod_nesting): load wrapping module should appear in
Module#nesting list. (ruby-bugs-ja:PR#328) * eval.c (rb_thread_remove): free stack buffer on remove. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2870 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
50cc115b7e
commit
73a47246f2
4 changed files with 20 additions and 7 deletions
|
@ -1,3 +1,10 @@
|
|||
Tue Sep 17 01:13:31 2002 Yukihiro Matsumoto <matz@ruby-lang.org>
|
||||
|
||||
* eval.c (rb_mod_nesting): load wrapping module should appear in
|
||||
Module#nesting list. (ruby-bugs-ja:PR#328)
|
||||
|
||||
* eval.c (rb_thread_remove): free stack buffer on remove.
|
||||
|
||||
Tue Sep 17 00:58:35 2002 Minero Aoki <aamine@loveruby.net>
|
||||
|
||||
* io.c: add parameter prototype.
|
||||
|
|
5
eval.c
5
eval.c
|
@ -1570,6 +1570,9 @@ rb_mod_nesting()
|
|||
if (!NIL_P(cbase->nd_clss)) rb_ary_push(ary, cbase->nd_clss);
|
||||
cbase = cbase->nd_next;
|
||||
}
|
||||
if (ruby_wrapper && RARRAY(ary)->len == 0) {
|
||||
rb_ary_push(ary, ruby_wrapper);
|
||||
}
|
||||
return ary;
|
||||
}
|
||||
|
||||
|
@ -7766,6 +7769,8 @@ rb_thread_remove(th)
|
|||
th->gid = 0;
|
||||
th->prev->next = th->next;
|
||||
th->next->prev = th->prev;
|
||||
if (th->stk_ptr) free(th->stk_ptr);
|
||||
th->stk_ptr = 0;
|
||||
}
|
||||
|
||||
static int
|
||||
|
|
14
marshal.c
14
marshal.c
|
@ -43,7 +43,7 @@ shortlen(len, ds)
|
|||
#endif
|
||||
|
||||
#define MARSHAL_MAJOR 4
|
||||
#define MARSHAL_MINOR 7
|
||||
#define MARSHAL_MINOR 8
|
||||
|
||||
#define TYPE_NIL '0'
|
||||
#define TYPE_TRUE 'T'
|
||||
|
@ -371,24 +371,24 @@ w_object(obj, arg, limit)
|
|||
|
||||
if (OBJ_TAINTED(obj)) arg->taint = Qtrue;
|
||||
|
||||
if (ivtbl = rb_generic_ivar_table(obj)) {
|
||||
w_byte(TYPE_IVAR, arg);
|
||||
}
|
||||
|
||||
st_add_direct(arg->data, obj, arg->data->num_entries);
|
||||
if (rb_respond_to(obj, s_dump)) {
|
||||
VALUE v;
|
||||
|
||||
w_byte(TYPE_USERDEF, arg);
|
||||
w_unique(rb_class2name(CLASS_OF(obj)), arg);
|
||||
w_class(TYPE_USERDEF, obj, arg);
|
||||
v = rb_funcall(obj, s_dump, 1, INT2NUM(limit));
|
||||
if (TYPE(v) != T_STRING) {
|
||||
rb_raise(rb_eTypeError, "_dump() must return String");
|
||||
}
|
||||
w_bytes(RSTRING(v)->ptr, RSTRING(v)->len, arg);
|
||||
if (ivtbl) w_ivar(ivtbl, &c_arg);
|
||||
return;
|
||||
}
|
||||
|
||||
if (ivtbl = rb_generic_ivar_table(obj)) {
|
||||
w_byte(TYPE_IVAR, arg);
|
||||
}
|
||||
|
||||
switch (BUILTIN_TYPE(obj)) {
|
||||
case T_CLASS:
|
||||
if (FL_TEST(obj, FL_SINGLETON)) {
|
||||
|
|
|
@ -1458,6 +1458,7 @@ original_module(c)
|
|||
|
||||
static void
|
||||
cvar_override_check(id, a)
|
||||
ID id;
|
||||
VALUE a;
|
||||
{
|
||||
VALUE base = original_module(a);
|
||||
|
|
Loading…
Reference in a new issue