rust/library/alloc/src/vec
bors df0295f071 Auto merge of #110353 - the8472:in-place-flatten-chunks, r=cuviper
Expand in-place iteration specialization to Flatten, FlatMap and ArrayChunks

This enables the following cases to collect in-place:

```rust
let v = vec![[0u8; 4]; 1024]
let v: Vec<_> = v.into_iter().flatten().collect();

let v: Vec<Option<NonZeroUsize>> = vec![NonZeroUsize::new(0); 1024];
let v: Vec<_> = v.into_iter().flatten().collect();

let v = vec![u8; 4096];
let v: Vec<_> = v.into_iter().array_chunks::<4>().collect();
```

Especially the nicheful-option-flattening should be useful in real code.
2023-11-28 12:22:16 +00:00
..
cow.rs remove some unneeded imports 2023-04-12 19:27:18 +02:00
drain.rs enable rust_2018_idioms for doctests 2023-05-07 00:12:29 +03:00
extract_if.rs remove unused field 2023-06-15 21:14:40 +02:00
in_place_collect.rs unchecked layout calculations when shrinking during in-place collect 2023-09-03 19:59:47 +02:00
in_place_drop.rs Fix leaking in inplace collection when destructor panics 2022-09-10 11:34:22 +02:00
into_iter.rs Auto merge of #110353 - the8472:in-place-flatten-chunks, r=cuviper 2023-11-28 12:22:16 +00:00
is_zero.rs Update IsZero documentation 2023-01-18 15:48:53 +00:00
mod.rs Add insta-stable std:#️⃣:{DefaultHasher, RandomState} exports 2023-11-02 20:35:20 -04:00
partial_eq.rs Allow comparing Vecs with different allocators using == 2022-02-08 01:50:55 +00:00
set_len_on_drop.rs Tune RepeatWith::try_fold and Take::for_each and Vec::extend_trusted 2022-11-24 19:14:19 -08:00
spec_extend.rs Remove lifetime bound for A for impl Extend<&'a T> for Vec<T, A>. 2023-07-01 02:12:45 -05:00
spec_from_elem.rs docs(GH-118094): make docs a bit more explicit 2023-11-20 18:35:04 +03:00
spec_from_iter.rs Update documentation of SpecFromIter to reflect the removed impls 2021-05-31 21:07:03 +02:00
spec_from_iter_nested.rs Improve estimation of capacity in Vec::from_iter 2022-01-19 09:47:49 -05:00
splice.rs enable rust_2018_idioms for doctests 2023-05-07 00:12:29 +03:00