summaryrefslogtreecommitdiff
path: root/vm.c
diff options
context:
space:
mode:
Diffstat (limited to 'vm.c')
-rw-r--r--vm.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/vm.c b/vm.c
index bc19f6f8ef..afcd5ca416 100644
--- a/vm.c
+++ b/vm.c
@@ -2153,12 +2153,10 @@ vm_define_method(rb_thread_t *th, VALUE obj, ID id, VALUE iseqval,
OBJ_WRITE(miseq->self, &miseq->klass, klass);
miseq->defined_method_id = id;
rb_add_method(klass, id, VM_METHOD_TYPE_ISEQ, miseq, noex);
- rb_clear_method_cache_by_class(klass);
if (!is_singleton && noex == NOEX_MODFUNC) {
klass = rb_singleton_class(klass);
rb_add_method(klass, id, VM_METHOD_TYPE_ISEQ, miseq, NOEX_PUBLIC);
- rb_clear_method_cache_by_class(klass);
}
}
@@ -2208,7 +2206,6 @@ m_core_undef_method(VALUE self, VALUE cbase, VALUE sym)
{
REWIND_CFP({
rb_undef(cbase, SYM2ID(sym));
- rb_clear_method_cache_by_class(cbase);
rb_clear_method_cache_by_class(self);
});
return Qnil;