mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* lib/irb*: merge doc from doc/irb/ird.rd and improve overall
documentation of IRB * doc/irb/irb.rd: remove stale documentation git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38358 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
0ac361f540
commit
8983315238
29 changed files with 432 additions and 23 deletions
|
|
@ -9,7 +9,7 @@
|
|||
#
|
||||
#
|
||||
|
||||
module IRB
|
||||
module IRB # :nodoc:
|
||||
class Context
|
||||
|
||||
def home_workspace
|
||||
|
|
@ -20,6 +20,13 @@ module IRB
|
|||
end
|
||||
end
|
||||
|
||||
# Changes the current workspace to given object or binding.
|
||||
#
|
||||
# If the optional argument is omitted, the workspace will be
|
||||
# #home_workspace which is inherited from +TOPLEVEL_BINDING+ or the main
|
||||
# object, <code>IRB.conf[:MAIN_CONTEXT]</code> when irb was initialized.
|
||||
#
|
||||
# See IRB::WorkSpace.new for more information.
|
||||
def change_workspace(*_main)
|
||||
if _main.empty?
|
||||
@workspace = home_workspace
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue