Sha256: e311053ddc2c6b4c38cd60b57fbef617751381e7c6ac4ef9ab4415f53e3f643e
Contents?: true
Size: 408 Bytes
Versions: 17
Compression:
Stored size: 408 Bytes
Contents
module FFI module IO def self.for_fd(fd, mode = "r") ::IO.for_fd(fd, mode) end # # A version of IO#read that reads into a native buffer # # This will be optimized at some future time to eliminate the double copy # def self.native_read(io, buf, len) tmp = io.read(len) return -1 unless tmp buf.put_bytes(0, tmp) tmp.length end end end
Version data entries
17 entries across 17 versions & 4 rubygems