diff options
Diffstat (limited to 'eval.c')
-rw-r--r-- | eval.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -370,7 +370,8 @@ rb_clear_cache_for_undef(klass, id) ent = cache; end = ent + CACHE_SIZE; while (ent < end) { if (ent->mid == id && - RCLASS(ent->origin)->m_tbl == RCLASS(klass)->m_tbl) { + (ent->klass == klass || + RCLASS(ent->origin)->m_tbl == RCLASS(klass)->m_tbl)) { ent->mid = 0; } ent++; |