diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2020-03-22 00:20:58 +0100 |
|---|---|---|
| committer | Matthias Krüger <matthias.krueger@famsik.de> | 2020-03-22 00:35:25 +0100 |
| commit | 74d68ea7ebe2085bba2758ccce366f1fa4fc6210 (patch) | |
| tree | 164b41576142a0d0476b1ec3c8c325abe260c03f /src/librustc_mir/dataflow | |
| parent | 3599fd389de25af78a4616015fa937ff3aeb661a (diff) | |
don't create variable bindings just to return the bound value immediately (clippy::let_and_return)
Diffstat (limited to 'src/librustc_mir/dataflow')
| -rw-r--r-- | src/librustc_mir/dataflow/move_paths/builder.rs | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/librustc_mir/dataflow/move_paths/builder.rs b/src/librustc_mir/dataflow/move_paths/builder.rs index 7c449ad1197..276aabec13d 100644 --- a/src/librustc_mir/dataflow/move_paths/builder.rs +++ b/src/librustc_mir/dataflow/move_paths/builder.rs @@ -184,14 +184,13 @@ impl<'b, 'a, 'tcx> Gatherer<'b, 'a, 'tcx> { .. } = self.builder; *rev_lookup.projections.entry((base, elem.lift())).or_insert_with(move || { - let path = MoveDataBuilder::new_move_path( + MoveDataBuilder::new_move_path( move_paths, path_map, init_path_map, Some(base), mk_place(*tcx), - ); - path + ) }) } |
