Skip to content

Commit 937bec4

Browse files
author
Henri Lunnikivi
committed
fixup! f3f389a
1 parent 4b06678 commit 937bec4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

clippy_lints/src/field_reassign_with_default.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62,12 +62,12 @@ impl LateLintPass<'_> for FieldReassignWithDefault {
6262
for consecutive_statement in &block.stmts[stmt_idx + 1..] {
6363
// interrupt if the statement is a let binding (`Local`) that shadows the original
6464
// binding
65-
if stmt_shadows_binding(consequtive_statement, binding_name) {
65+
if stmt_shadows_binding(consecutive_statement, binding_name) {
6666
break;
6767
}
6868
// find out if and which field was set by this `consecutive_statement`
6969
else if let Some((field_ident, assign_rhs)) =
70-
field_reassigned_by_stmt(consequtive_statement, binding_name)
70+
field_reassigned_by_stmt(consecutive_statement, binding_name)
7171
{
7272
// extract and store the assigned value for help message
7373
let value_snippet = snippet(cx, assign_rhs.span, "..");
@@ -77,7 +77,7 @@ impl LateLintPass<'_> for FieldReassignWithDefault {
7777

7878
// also set first instance of error for help message
7979
if first_assign.is_none() {
80-
first_assign = Some(consequtive_statement);
80+
first_assign = Some(consecutive_statement);
8181
}
8282
}
8383
// interrupt also if no field was assigned, since we only want to look at consecutive statements

0 commit comments

Comments
 (0)