#576: It's possible to close STDOUT (and presumably other standard IO streams) -----------------------------------+---------------------------------------- Reporter: matt...@… | Owner: lsansone...@… Type: defect | Status: new Priority: critical | Milestone: MacRuby 0.5 Component: MacRuby | Keywords: -----------------------------------+---------------------------------------- Run the following in irb, then macirb:
{{{ STDOUT.close }}} '''Expected (Ruby 1.9.1):''' {{{ => nil }}} '''Actual (MacRuby 0.5 beta 2):''' {{{ (closes interpreter) }}} The expected behavior is to ignore close requests to standard IO streams. Ruby does this, but MacRuby does not. When using macirb, calling {{{STDOUT.close}}} simply closes the interpreter, whereas in Ruby it returns nil. This has important real-world implications when dealing with logging. Consider logging to STDOUT; Logger#close actually closes the STDOUT stream! -- Ticket URL: <http://www.macruby.org/trac/ticket/576> MacRuby <http://macruby.org/> _______________________________________________ MacRuby-devel mailing list MacRuby-devel@lists.macosforge.org http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel