Files
rust/library/std/src/net
Jonathan Brouwer b7c319cfc4 Rollup merge of #150129 - a1phyr:improve_buf_api, r=joshtriplett
`BorrowedCursor`: make `init` a boolean

This PR changes uninitialized bytes tracking in `BorrowedBuf` from being byte-wise to being buffer-wise.

I've put all the API around `init` a new unstable feature `borrowed_buf_init`, to split the part that needs it and the part that doesn't. It will avoids accidental stabilization of this part.

I'm not really convinced of the rename of `advance_unchecked` to `advance`, but I did it anyway. The old `advance` was kept as `advance_checked`.

Alternative of rust-lang/rust#148937

Cc rust-lang/rust#78485 rust-lang/rust#117693
Cc @joshtriplett

r? @Amanieu
2026-04-05 00:18:45 +02:00
..
2025-03-04 10:06:28 -05:00