$DEFAULT_OUTPUT -> IO
[permalink][rdoc] [added by English]
$> の別名
require "English" dout = $DEFAULT_OUTPUT.dup $DEFAULT_OUTPUT.reopen("out.txt", "w") print "foo" $DEFAULT_OUTPUT.close $DEFAULT_OUTPUT = dout p "bar" # => bar p File.read("out.txt") #=> foo