about summary refs log tree commit diff
path: root/src/rustllvm/RustWrapper.cpp
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2014-06-05 00:51:48 -0700
committerbors <bors@rust-lang.org>2014-06-05 00:51:48 -0700
commit0c74911f87c12f0680e21e49a8f9c0c85affac78 (patch)
tree4589ae45e62f8e981e35c500f1c842225343b3e0 /src/rustllvm/RustWrapper.cpp
parent073c8f10fc40b07596fd1018a2002db8e6d5222a (diff)
parent30a8bcbe3df484f7fa9f2523f429490c97af0382 (diff)
downloadrust-0c74911f87c12f0680e21e49a8f9c0c85affac78.tar.gz
rust-0c74911f87c12f0680e21e49a8f9c0c85affac78.zip
auto merge of #14568 : erickt/rust/slice-update, r=alexcrichton
This PR adds two features to make it possible to transform an `Iterator<u8>` into a `Reader`. The first patch adds a method to mutable slices that allows it to be updated with an `Iterator<T>` without paying for the bounds cost. The second adds a Iterator adaptor, `IterReader`, to provide that `Reader` interface.

I had two questions. First, are these named the right things? Second, should `IterReader` instead wrap an `Iterator<Result<u8, E>>`? This would allow you to `IterReader::new(rdr.bytes())`, which could be useful if you want to apply some iterator transformations on a reader while still exporting the Reader interface, but I'd expect there'd be a lot of overhead annotating each byte with an error result.
Diffstat (limited to 'src/rustllvm/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions