Skip to content

Commit 98c2c34

Browse files
committed
Fix rustfmt
1 parent ddc6843 commit 98c2c34

File tree

2 files changed

+12
-6
lines changed

2 files changed

+12
-6
lines changed

clippy_lints/src/assign_ops.rs

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,11 @@ impl<'a, 'tcx> LateLintPass<'a, 'tcx> for AssignOps {
9797
|db| if let (Some(snip_a), Some(snip_r)) =
9898
(snippet_opt(cx, assignee.span), snippet_opt(cx, rhs.span)) {
9999
db.span_suggestion(expr.span,
100-
"replace it with",
101-
format!("{} {}= {}", snip_a, op.node.as_str(), snip_r));
100+
"replace it with",
101+
format!("{} {}= {}",
102+
snip_a,
103+
op.node.as_str(),
104+
snip_r));
102105
});
103106
};
104107
// lhs op= l op r
@@ -178,8 +181,11 @@ impl<'a, 'tcx> LateLintPass<'a, 'tcx> for AssignOps {
178181
|db| if let (Some(snip_a), Some(snip_r)) =
179182
(snippet_opt(cx, assignee.span), snippet_opt(cx, rhs.span)) {
180183
db.span_suggestion(expr.span,
181-
"replace it with",
182-
format!("{} {}= {}", snip_a, op.node.as_str(), snip_r));
184+
"replace it with",
185+
format!("{} {}= {}",
186+
snip_a,
187+
op.node.as_str(),
188+
snip_r));
183189
});
184190
}
185191
};

clippy_lints/src/map_clone.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
use rustc::lint::*;
22
use rustc::hir::*;
33
use syntax::ast;
4-
use utils::{is_adjusted, match_path, match_trait_method, match_type, remove_blocks, paths, snippet,
5-
span_help_and_lint, walk_ptrs_ty, walk_ptrs_ty_depth, iter_input_pats};
4+
use utils::{is_adjusted, match_path, match_trait_method, match_type, remove_blocks, paths, snippet, span_help_and_lint,
5+
walk_ptrs_ty, walk_ptrs_ty_depth, iter_input_pats};
66

77
/// **What it does:** Checks for mapping `clone()` over an iterator.
88
///

0 commit comments

Comments
 (0)