mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
Should not call initialize_copy for TT_ICLASS; fix #4027
Since `TT_ICLASS` is a internal object that should never be revealed to Ruby world.
This commit is contained in:
@@ -279,6 +279,9 @@ static void
|
||||
init_copy(mrb_state *mrb, mrb_value dest, mrb_value obj)
|
||||
{
|
||||
switch (mrb_type(obj)) {
|
||||
case MRB_TT_ICLASS:
|
||||
copy_class(mrb, dest, obj);
|
||||
return;
|
||||
case MRB_TT_CLASS:
|
||||
case MRB_TT_MODULE:
|
||||
copy_class(mrb, dest, obj);
|
||||
|
||||
Reference in New Issue
Block a user