In_buf.t_from_refill
A mixin to implement a buffered input by only providing a refill
method. Add a close
method and it's good to go.
Implementation of the stream: this takes a slice, resets its offset, and fills it with bytes. It must write at least one byte in the slice, unless the underlying input has reached its end.