rust/library/core
Guillaume Gomez a181806b8c
Rollup merge of #85338 - lopopolo:core-iter-repeat-gh-81292, r=joshtriplett
Implement more Iterator methods on core::iter::Repeat

`core::iter::Repeat` always returns the same element, which means we can
do better than implementing most `Iterator` methods in terms of
`Iterator::next`.

Fixes #81292.

#81292 raises the question of whether these changes violate the contract of `core::iter::Repeat`, but as far as I can tell `core::iter::repeat` doesn't make any guarantees around how it calls `Clone::clone`.
2021-05-18 14:08:46 +02:00
..
benches move core::hint::black_box under its own feature gate 2021-04-25 11:08:12 +02:00
src Rollup merge of #85338 - lopopolo:core-iter-repeat-gh-81292, r=joshtriplett 2021-05-18 14:08:46 +02:00
tests Rollup merge of #84105 - WaffleLapkin:stabilize_array_from_ref, r=m-ou-se 2021-04-25 01:53:10 +09:00
Cargo.toml Auto merge of #82271 - Aaron1011:debug-refcell, r=m-ou-se 2021-03-23 04:49:47 +00:00