summaryrefslogtreecommitdiff
path: root/ext/objspace/objspace.c
diff options
context:
space:
mode:
Diffstat (limited to 'ext/objspace/objspace.c')
-rw-r--r--ext/objspace/objspace.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/ext/objspace/objspace.c b/ext/objspace/objspace.c
index e61ae3f21f7..e61eda8ab94 100644
--- a/ext/objspace/objspace.c
+++ b/ext/objspace/objspace.c
@@ -69,6 +69,9 @@ memsize_of(VALUE obj)
if (RCLASS(obj)->ptr->iv_tbl) {
size += st_memsize(RCLASS(obj)->ptr->iv_tbl);
}
+ if (RCLASS(obj)->ptr->const_tbl) {
+ size += st_memsize(RCLASS(obj)->ptr->const_tbl);
+ }
size += sizeof(rb_classext_t);
break;
case T_STRING: