rust/crates
bors[bot] c0459c5357
Merge #7956
7956: Add assist to convert for_each into for loops r=Veykril a=SaiintBrisson

This PR resolves #7821.
Adds an assist to that converts an `Iterator::for_each` into a for loop: 

```rust
fn main() {
    let vec = vec![(1, 2), (2, 3), (3, 4)];
    x.iter().for_each(|(x, y)| {
        println!("x: {}, y: {}", x, y);
    })
}
```
becomes
```rust
fn main() {
    let vec = vec![(1, 2), (2, 3), (3, 4)];
    for (x, y) in x.iter() {
        println!("x: {}, y: {}", x, y);
    });
}
```

Co-authored-by: Luiz Carlos Mourão Paes de Carvalho <luizcarlosmpc@gmail.com>
Co-authored-by: Luiz Carlos <luizcarlosmpc@gmail.com>
Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2021-03-12 14:45:04 +00:00
..
base_db
cfg
flycheck Bump cargo_metadata 2021-03-02 14:27:29 +02:00
hir Avoid double text edits when renaming mod declaration 2021-03-10 15:49:01 +01:00
hir_def Prefer names from outer DefMap over extern prelude 2021-03-10 16:33:18 +01:00
hir_expand Use expect-test for builtin macro/derive tests 2021-03-10 21:05:02 +01:00
hir_ty Prefer names from outer DefMap over extern prelude 2021-03-10 16:33:18 +01:00
ide remove unused CompletionScore enum 2021-03-12 06:16:04 -08:00
ide_assists Merge #7956 2021-03-12 14:45:04 +00:00
ide_completion update relevance score u8 -> u32 2021-03-12 06:16:04 -08:00
ide_db Compilation speed 2021-03-09 22:30:58 +03:00
ide_ssr Merge #7961 2021-03-10 17:06:11 +00:00
mbe Compilation speed 2021-03-09 22:30:58 +03:00
parser Fix remaining references to cargo xtask codegen 2021-03-12 15:10:33 +01:00
paths
proc_macro_api use doc-comments 2021-03-10 04:54:31 +08:00
proc_macro_srv Compilation speed 2021-03-09 22:30:58 +03:00
proc_macro_test
profile
project_model Never run cargo check on the rustc source 2021-03-08 16:42:18 +00:00
rust-analyzer update relevance score u8 -> u32 2021-03-12 06:16:04 -08:00
stdx
syntax Merge #7956 2021-03-12 14:45:04 +00:00
test_utils Use upstream cov-mark 2021-03-08 22:19:44 +02:00
text_edit
toolchain
tt
vfs
vfs-notify