diff options
| author | bors <bors@rust-lang.org> | 2021-04-06 09:57:12 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2021-04-06 09:57:12 +0000 |
| commit | e1d49aaad4fde33469fdb786c29838a95a5d8a11 (patch) | |
| tree | f8bd5b8d81b65b9c697a7e4ab27498c598eacc41 /compiler/rustc_codegen_llvm/src | |
| parent | 354cc751b74e813f180755fa67bebcb669825755 (diff) | |
| parent | 09ff88b600713a2bfca7cfdfd1828b519c907247 (diff) | |
| download | rust-e1d49aaad4fde33469fdb786c29838a95a5d8a11.tar.gz rust-e1d49aaad4fde33469fdb786c29838a95a5d8a11.zip | |
Auto merge of #83821 - camelid:improve-thinvec, r=petrochenkov
Add `FromIterator` and `IntoIterator` impls for `ThinVec` These should make using `ThinVec` feel much more like using `Vec`. They will allow users of `Vec` to switch to `ThinVec` while continuing to use `collect()`, `for` loops, and other parts of the iterator API. I don't know if there were use cases before for using the iterator API with `ThinVec`, but I would like to start using `ThinVec` in rustdoc, and having it conform to the iterator API would make the transition *a lot* easier. I added a `FromIterator` impl, an `IntoIterator` impl that yields owned elements, and `IntoIterator` impls that yield immutable or mutable references to elements. I also added some unit tests for `ThinVec`.
Diffstat (limited to 'compiler/rustc_codegen_llvm/src')
0 files changed, 0 insertions, 0 deletions
