summaryrefslogtreecommitdiff
path: root/vm_method.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-10-09 02:57:29 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-10-09 02:57:29 +0000
commita23878c3f5f78522d1c977ff59df936a16abcaa6 (patch)
tree2743684b55509e57e39b6612b44c3f517150b1a6 /vm_method.c
parent95c044c4a92f7de5a13fac0b29207ee71fb54962 (diff)
vm_method.c: update assertion [ci skip]
* vm_method.c (prepare_callable_method_entry): update assertion as defined_class may be T_MODULE not only I_ICLASS since r56213. [Feature #12534] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56380 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'vm_method.c')
-rw-r--r--vm_method.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/vm_method.c b/vm_method.c
index d5780bbe8f..93f65495fc 100644
--- a/vm_method.c
+++ b/vm_method.c
@@ -804,7 +804,7 @@ prepare_callable_method_entry(VALUE defined_class, ID id, const rb_method_entry_
const rb_callable_method_entry_t *cme;
if (me && me->defined_class == 0) {
- VM_ASSERT(RB_TYPE_P(defined_class, T_ICLASS));
+ VM_ASSERT(RB_TYPE_P(defined_class, T_ICLASS) || RB_TYPE_P(defined_class, T_MODULE));
VM_ASSERT(me->defined_class == 0);
if ((mtbl = RCLASS_CALLABLE_M_TBL(defined_class)) == NULL) {