class IO
def self.Stream(io)
def self.Stream(io) if io.is_a?(Stream::Buffered) io else Stream::Buffered.wrap(io) end end
def buffered=(value)
def buffered=(value) self.sync = !value end
def buffered?
def buffered? return !self.sync end
def readable?
def readable? # Do not call `eof?` here as it is not concurrency-safe and it can block. !closed? end