diff options
| author | bors <bors@rust-lang.org> | 2021-01-11 18:50:53 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2021-01-11 18:50:53 +0000 |
| commit | c5eae562935922f712edec56a45591bc2f8ded1c (patch) | |
| tree | 35af8ef473d32f7e42de1dfe9cf423f7b97f9b35 /compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp | |
| parent | 6526e5c772f2da07db745c94ca6bb0a591a39ba4 (diff) | |
| parent | 4038042eb0f9e8088974f1d9342103ed1b5de31f (diff) | |
| download | rust-c5eae562935922f712edec56a45591bc2f8ded1c.tar.gz rust-c5eae562935922f712edec56a45591bc2f8ded1c.zip | |
Auto merge of #75490 - LukasKalbertodt:add-basic-array-methods, r=dtolnay
Add `[T; N]::each_ref` and `[T; N]::each_mut`
This PR adds the methods `each_ref` and `each_mut` to `[T; N]`. The ability to add methods to arrays was added in #75212. These two methods are particularly useful with `map` which was also added in that PR. Tracking issue: #76118
```rust
impl<T, const N: usize> [T; N] {
pub fn each_ref(&self) -> [&T; N];
pub fn each_mut(&mut self) -> [&mut T; N];
}
```
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions
