Feature gate: #![feature(read_buf_at)]
This is a tracking issue for FileExt::read_buf_at() and related methods, providing positioned reads into unintialized buffers.
#![feature(read_buf)] adds support for reads into unintialized buffers via BorrowedBuf and BorrowedCursor. This feature expands that to reads from specific offsets.
Public API
// std::os::unix::fs
trait FileExt {
// [...] (existing methods)
/// Equivalent to read_at()
fn read_buf_at(&self, buf: BorrowedCursor<'_>, offset: u64) -> io::Result<()>;
/// Equivalent to read_exact_at()
fn read_buf_exact_at(&self, buf: BorrowedCursor<'_>, offset: u64) -> io::Result<()>;
}
// std::os::windows::fs
trait FileExt {
// [...] (existing methods)
/// Equivalent to seek_read()
fn seek_read_buf(&self, buf: BorrowedCursor<'_>, offset: u64) -> io::Result<()>;
}
Steps / History
Unresolved Questions
Feature gate:
#![feature(read_buf_at)]This is a tracking issue for
FileExt::read_buf_at()and related methods, providing positioned reads into unintialized buffers.#![feature(read_buf)]adds support for reads into unintialized buffers viaBorrowedBufandBorrowedCursor. This feature expands that to reads from specific offsets.Public API
Steps / History
FileExt::read_buf_at, ...) libs-team#581read_bufequivalents for positioned reads #140459Unresolved Questions
#![feature(core_io_borrowed_buf)]changes before stabilization?#![feature(read_buf)]changes before stabilization?Footnotes
https://std-dev-guide.rust-lang.org/feature-lifecycle/stabilization.html ↩