Skip to content

Commit

Permalink
Use ".." as default value of snippet in excessive_for_each
Browse files Browse the repository at this point in the history
  • Loading branch information
Y-Nak committed Feb 27, 2021
1 parent 103dc83 commit dbadac7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions clippy_lints/src/methods/excessive_for_each.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ pub(super) fn lint(cx: &LateContext<'_>, expr: &'tcx Expr<'_>, args: &[&[Expr<'_

let sugg = format!(
"for {} in {} {{ .. }}",
snippet(cx, body.params[0].pat.span, ""),
snippet(cx, for_each_receiver.span, "")
snippet(cx, body.params[0].pat.span, ".."),
snippet(cx, for_each_receiver.span, "..")
);

span_lint_and_then(
Expand Down

0 comments on commit dbadac7

Please sign in to comment.