Feature #2740 » const_missing_nesting.diff
variable.c | ||
---|---|---|
static VALUE
|
||
const_missing(VALUE klass, ID id)
|
||
{
|
||
return rb_funcall(klass, rb_intern("const_missing"), 1, ID2SYM(id));
|
||
ID const_missing_id = rb_intern("const_missing");
|
||
int arity = rb_obj_method_arity(klass, const_missing_id);
|
||
|
||
if(arity == 1)
|
||
return rb_funcall(klass, const_missing_id, 1, ID2SYM(id));
|
||
else
|
||
return rb_funcall(klass, const_missing_id, 2, ID2SYM(id), rb_funcall(rb_cModule, rb_intern("nesting"), 0));
|
||
}
|
||