diff options
| author | blake2-ppc <blake2-ppc> | 2013-08-30 19:59:49 +0200 |
|---|---|---|
| committer | blake2-ppc <blake2-ppc> | 2013-08-30 20:03:40 +0200 |
| commit | 4b2cc22031d56a4846bc0ad4e65e19892db734c4 (patch) | |
| tree | fd0936df8c0f8eddda113da78792ceb18616fdf6 /src/rt/jemalloc/test/aligned_alloc.c | |
| parent | 0ac3e023d86fa84ed38bca3d34003b494fd28acf (diff) | |
| download | rust-4b2cc22031d56a4846bc0ad4e65e19892db734c4.tar.gz rust-4b2cc22031d56a4846bc0ad4e65e19892db734c4.zip | |
std::iterator: Introduce trait ExactSizeHint
The trait `ExactSizeHint` is introduced to solve a few small niggles: * We can't reverse (`.invert()`) an enumeration iterator * for a vector, we have `v.iter().position(f)` but `v.rposition(f)`. * We can't reverse `Zip` even if both iterators are from vectors `ExactSizeHint` is an empty trait that is intended to indicate that an iterator, for example `VecIterator`, knows its exact finite size and reports it correctly using `.size_hint()`. Only adaptors that preserve this at all times, can expose this trait further. (Where here we say finite for fitting in uint).
Diffstat (limited to 'src/rt/jemalloc/test/aligned_alloc.c')
0 files changed, 0 insertions, 0 deletions
