Closed hanachin closed 7 years ago
Init_top_self(void)
{
rb_vm_t *vm = GET_VM();
vm->top_self = rb_obj_alloc(rb_cObject);
rb_define_singleton_method(rb_vm_top_self(), "to_s", main_to_s, 0);
rb_define_alias(rb_singleton_class(rb_vm_top_self()), "inspect", "to_s");
}
https://github.com/ruby/ruby/blob/c08f7b80889b531865e74bc5f573df8fa27f2088/vm.c#L3169,L3177
Before you submit the issue, please provide us following information:
$GOBY_ROOT
in MRI, the top level main object is printed as "main"
But goby doesn't