summaryrefslogtreecommitdiff
path: root/proc.c
diff options
context:
space:
mode:
Diffstat (limited to 'proc.c')
-rw-r--r--proc.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/proc.c b/proc.c
index f8b2e3b3a9..2630df15d0 100644
--- a/proc.c
+++ b/proc.c
@@ -14,7 +14,7 @@
#include "gc.h"
#include "iseq.h"
-NODE *rb_vm_cref_in_context(VALUE self);
+const NODE *rb_vm_cref_in_context(VALUE self, VALUE cbase);
struct METHOD {
VALUE recv;
@@ -1622,9 +1622,9 @@ rb_mod_define_method(int argc, VALUE *argv, VALUE mod)
ID id;
VALUE body;
int noex = NOEX_PUBLIC;
- const NODE *cref = rb_vm_cref_in_context(mod);
+ const NODE *cref = rb_vm_cref_in_context(mod, mod);
- if (cref && cref->nd_clss == mod) {
+ if (cref) {
noex = (int)cref->nd_visi;
}