about summary refs log tree commit diff
path: root/src/test/debuginfo/enum-thinlto.rs
diff options
context:
space:
mode:
authorDylan DPC <dylan.dpc@gmail.com>2020-04-27 22:14:55 +0200
committerGitHub <noreply@github.com>2020-04-27 22:14:55 +0200
commitc4d9f42f6d29b9c7bf8f6ca98be02621724cb9d2 (patch)
treefaf85c1d2ef5b674504ce069afa249e1f4e22b31 /src/test/debuginfo/enum-thinlto.rs
parent46ec74e60f238f694b46c976d6217e7cf8d4cf1a (diff)
parentc68f23ff6d670e579e0951352e20a1495b66fce0 (diff)
downloadrust-c4d9f42f6d29b9c7bf8f6ca98be02621724cb9d2.tar.gz
rust-c4d9f42f6d29b9c7bf8f6ca98be02621724cb9d2.zip
Rollup merge of #67841 - sfackler:can-vector, r=Amaneiu
Add Read/Write::can_read/write_vectored

When working with an arbitrary reader or writer, code that uses vectored
operations may end up being slower than code that copies into a single
buffer when the underlying reader or writer doesn't actually support
vectored operations. These new methods allow you to ask the reader or
witer up front if vectored operations are efficiently supported.

Currently, you have to use some heuristics to guess by e.g. checking if
the read or write only accessed the first buffer. Hyper is one concrete
example of a library that has to do this dynamically:
https://github.com/hyperium/hyper/blob/0eaf304644a396895a4ce1f0146e596640bb666a/src/proto/h1/io.rs#L582-L594
Diffstat (limited to 'src/test/debuginfo/enum-thinlto.rs')
0 files changed, 0 insertions, 0 deletions