diff options
Diffstat (limited to 'vm_eval.c')
-rw-r--r-- | vm_eval.c | 21 |
1 files changed, 10 insertions, 11 deletions
@@ -487,19 +487,18 @@ rb_search_method_entry(VALUE recv, ID mid, VALUE *defined_class_ptr) VALUE klass = CLASS_OF(recv); if (!klass) { - VALUE flags, klass; - if (IMMEDIATE_P(recv)) { + VALUE flags; + if (SPECIAL_CONST_P(recv)) { rb_raise(rb_eNotImpError, "method `%"PRIsVALUE"' called on unexpected immediate object (%p)", rb_id2str(mid), (void *)recv); } flags = RBASIC(recv)->flags; - klass = RBASIC(recv)->klass; if (flags == 0) { rb_raise(rb_eNotImpError, "method `%"PRIsVALUE"' called on terminated object" - " (%p flags=0x%"PRIxVALUE" klass=0x%"PRIxVALUE")", - rb_id2str(mid), (void *)recv, flags, klass); + " (%p flags=0x%"PRIxVALUE")", + rb_id2str(mid), (void *)recv, flags); } else { int type = BUILTIN_TYPE(recv); @@ -507,18 +506,18 @@ rb_search_method_entry(VALUE recv, ID mid, VALUE *defined_class_ptr) if (typestr && T_OBJECT <= type && type < T_NIL) rb_raise(rb_eNotImpError, "method `%"PRIsVALUE"' called on hidden %s object" - " (%p flags=0x%"PRIxVALUE" klass=0x%"PRIxVALUE")", - rb_id2str(mid), typestr, (void *)recv, flags, klass); + " (%p flags=0x%"PRIxVALUE")", + rb_id2str(mid), typestr, (void *)recv, flags); if (typestr) rb_raise(rb_eNotImpError, "method `%"PRIsVALUE"' called on unexpected %s object" - " (%p flags=0x%"PRIxVALUE" klass=0x%"PRIxVALUE")", - rb_id2str(mid), typestr, (void *)recv, flags, klass); + " (%p flags=0x%"PRIxVALUE")", + rb_id2str(mid), typestr, (void *)recv, flags); else rb_raise(rb_eNotImpError, "method `%"PRIsVALUE"' called on broken T_???" "(0x%02x) object" - " (%p flags=0x%"PRIxVALUE" klass=0x%"PRIxVALUE")", - rb_id2str(mid), type, (void *)recv, flags, klass); + " (%p flags=0x%"PRIxVALUE")", + rb_id2str(mid), type, (void *)recv, flags); } } return rb_method_entry(klass, mid, defined_class_ptr); |