Support for the Ruby 2.1 series ended on March 31 2017. See here for details.

In Files

  • io.c


Class/Module Index [+]

toggle debugging


Raised when an IO operation fails."/etc/hosts") {|f| f << "example"}
  #=> IOError: not opened for writing"/etc/hosts") {|f| f.close; }
  #=> IOError: closed stream

Note that some IO failures raise +SystemCallError+s and these are not subclasses of IOError:"does/not/exist")
  #=> Errno::ENOENT: No such file or directory - does/not/exist