Tracking Issue for RFC 2930 (read-buf) · Issue #78485 · rust-lang/rust (original) (raw)
Navigation Menu
- Explore
- Pricing
Provide feedback
Saved searches
Use saved searches to filter your results more quickly
Description
This is a tracking issue for the RFC "2930" (rust-lang/rfcs#2930).
The feature gate for the issue is #![feature(read_buf)]
.
This is now called BorrowedBuf
rather than ReadBuf
.
About tracking issues
Tracking issues are used to record the overall progress of implementation.
They are also used as hubs connecting to other relevant issues, e.g., bugs or open design questions.
A tracking issue is however not meant for large scale discussion, questions, or bug reports about a feature.
Instead, open a dedicated issue for the specific matter and add the relevant feature gate label.
Steps
- Implement the RFC
- Initial implementation in Implement most of RFC 2930, providing the ReadBuf abstraction #81156
- Vectorized APIs (
read_buf_vectored
,ReadBufs
).
- Adjust documentation (see instructions on rustc-dev-guide)
- Stabilization PR (see instructions on rustc-dev-guide)
- Note that this is a use of
rustc_must_implement_one_of
, which is a language-observable thing, and thus needs some amount of oversight/documentation about that as a prerequisite of stabilization.
- Note that this is a use of
Unresolved Questions
- Should
read_buf
return the number of bytes read likeread
does or should theReadBuf
track it instead? Some operations, like checking for EOF, are a bit simpler ifread_buf
returns the value, but the confusion around what is and is not trustworthy is worrysome for unsafe code working withRead
implementations. - What should assume_init be named?
- Should the API use a wrapper around &mut ReadBuf to prevent unexpected swapping of the caller-provided ReadBuf?
- Resolve soundness issue: Unsound BufWriter copy_to specialization with the unstable read_buf feature #93305