Skip to content

Commit ba9d143

Browse files
committed
liveness: Fix typo report_unsed_assign -> report_unused_assign
1 parent 42816d6 commit ba9d143

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

compiler/rustc_passes/src/liveness.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -1476,7 +1476,7 @@ impl<'tcx> Liveness<'_, 'tcx> {
14761476
for p in body.params {
14771477
self.check_unused_vars_in_pat(&p.pat, Some(entry_ln), |spans, hir_id, ln, var| {
14781478
if !self.live_on_entry(ln, var) {
1479-
self.report_unsed_assign(hir_id, spans, var, |name| {
1479+
self.report_unused_assign(hir_id, spans, var, |name| {
14801480
format!("value passed to `{}` is never read", name)
14811481
});
14821482
}
@@ -1615,13 +1615,13 @@ impl<'tcx> Liveness<'_, 'tcx> {
16151615

16161616
fn warn_about_dead_assign(&self, spans: Vec<Span>, hir_id: HirId, ln: LiveNode, var: Variable) {
16171617
if !self.live_on_exit(ln, var) {
1618-
self.report_unsed_assign(hir_id, spans, var, |name| {
1618+
self.report_unused_assign(hir_id, spans, var, |name| {
16191619
format!("value assigned to `{}` is never read", name)
16201620
});
16211621
}
16221622
}
16231623

1624-
fn report_unsed_assign(
1624+
fn report_unused_assign(
16251625
&self,
16261626
hir_id: HirId,
16271627
spans: Vec<Span>,

0 commit comments

Comments
 (0)