Inherits IO < Reference < Object
Does nothing but must be implemented since Crystal does not differentiate between Writesr/Readers
Writes the contents of slice into this IO.
IO
io = IO::Memory.new slice = Bytes.new(4) { |i| ('a'.ord + i).to_u8 } io.write(slice) io.to_s # => "abcd"