Issue #6263 has been reported by trans (Thomas Sawyer).

----------------------------------------
Feature #6263: Simple access to toplevel object (main)
https://bugs.ruby-lang.org/issues/6263

Author: trans (Thomas Sawyer)
Status: Open
Priority: Normal
Assignee: 
Category: 
Target version: 2.0.0


Maybe I miss something, but why is there no way to get toplevel object easily. Only way seems to be:

    main = eval('self', TOPLEVEL_BINDING)

Would be nice if there were a simple way, maybe special global `$main` would be good choice.



-- 
http://bugs.ruby-lang.org/