summaryrefslogtreecommitdiff
path: root/class.c
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2021-09-01 18:45:03 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2021-09-01 19:28:54 +0900
commit10ebf87428fa41dcbb179f8a35428fb63dc69d5c (patch)
treecf86f5d3ed2fbc0d4991bca6091b9ef0721a8fa2 /class.c
parentf9bdb17c02ff012b6b9bb46463a3596b6f99f144 (diff)
downloadruby-10ebf87428fa41dcbb179f8a35428fb63dc69d5c.tar.gz
Assert not to be UNDEF visibility
Any defined methods, bound to any classes/modules and not being UNDEFINED_METHOD_ENTRY_P, should not be METHOD_VISI_UNDEF.
Diffstat (limited to 'class.c')
-rw-r--r--class.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/class.c b/class.c
index 4c469ffaeb..b7247e7489 100644
--- a/class.c
+++ b/class.c
@@ -1435,6 +1435,7 @@ method_entry_i(ID key, VALUE value, void *data)
}
else {
type = METHOD_ENTRY_VISI(me);
+ RUBY_ASSERT(type != METHOD_VISI_UNDEF);
}
st_add_direct(arg->list, key, (st_data_t)type);
}