Uh oh!
There was an error while loading. Please reload this page.
Add io::Write::write_all_vectored - #70612
Conversation
rust-highfive
commented
Mar 31, 2020
(rust_highfive has picked a reviewer for you, use r? to override) |
Thomasdezeeuw
commented
Mar 31, 2020
I went with the original implementation I suggested, just to get some experience with it. I was thinking that maybe we could always set |
Centril
commented
Mar 31, 2020
@Thomasdezeeuw Can you split the module after this PR? It's getting close to the 3000 LOC threshold. |
Thomasdezeeuw
commented
Mar 31, 2020
@Centril Sure, anything you suggest that should move to its own file? Or should I start with moving the tests? Also I only ran libcore tests locally, so I'll fix the pr and push :) |
Centril
commented
Mar 31, 2020
@Thomasdezeeuw Some themes to consider:
|
rust-highfive
commented
Mar 31, 2020
The job Click to expand the log.I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
Similar to io::Write::write_all but uses io::Write::write_vectored instead.
Uh oh!
There was an error while loading. Please reload this page.
rust-highfive
commented
Mar 31, 2020
The job Click to expand the log.I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
rust-highfive
commented
Apr 1, 2020
The job Click to expand the log.I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
LukasKalbertodt
left a comment
There was a problem hiding this comment.
A few inline comments, mostly documentation though.
Regarding the discussion in #70436: I am also not very happy about an API like this. Especially since we recommend in the docs to "treat it as if bufs was consumed by this method". Feels wrong to me, as in Rust, we should be able to assert this on a type level somehow. But maybe it's not that bad, as this is mainly a fairly low level API anyway. And unfortunately, I don't have a great idea how to use the type system to make this better.
I personally don't like the idea of making this method implementation more complicated or slower to get around this API quirk. So I'm not quite sure what to do about this...
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Also adds some more tests with different length IoSlices.
Thomasdezeeuw
commented
Apr 6, 2020
@LukasKalbertodt I've address all comments, except for the tracking issue one. |
LukasKalbertodt
left a comment
There was a problem hiding this comment.
One tiny thing still!
Uh oh!
There was an error while loading. Please reload this page.
LukasKalbertodt
commented
Apr 6, 2020
Thanks! As I said, I don't particularly like the API. But let's get it landed, it's unstable after all. We can still change and discuss the exact API later. @bors r+ |
bors
commented
Apr 6, 2020
📌 Commit 5d09f9f has been approved by |
…albertodt Add io::Write::write_all_vectored Similar to io::Write::write_all but uses io::Write::write_vectored instead. Updates rust-lang#70436 /cc @cramertj@sfackler
…albertodt Add io::Write::write_all_vectored Similar to io::Write::write_all but uses io::Write::write_vectored instead. Updates rust-lang#70436 /cc @cramertj@sfackler
…albertodt Add io::Write::write_all_vectored Similar to io::Write::write_all but uses io::Write::write_vectored instead. Updates rust-lang#70436 /cc @cramertj@sfackler
Rollup of 5 pull requests Successful merges: - rust-lang#70612 (Add io::Write::write_all_vectored) - rust-lang#70690 (Clean up E0501 explanation) - rust-lang#70821 (expose suggestions::InferCtxtExt for clippy) - rust-lang#70839 (clean up E0506 explanation) - rust-lang#70859 (Move sanitize-inline-always test to sanitize directory) Failed merges: r? @ghost
joshtriplett
commented
Apr 14, 2020
I'm very happy to see this method added, thank you! |
Similar to io::Write::write_all but uses io::Write::write_vectored
instead.
Updates #70436
/cc @cramertj@sfackler