Skip to content

Commit 7adfb44

Browse files
committed
add trivial comments
1 parent f9ef7e2 commit 7adfb44

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

compiler/rustc_resolve/src/late/diagnostics.rs

+3-2
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,7 @@ pub(super) enum LifetimeElisionCandidate {
130130
Missing(MissingLifetime),
131131
}
132132

133+
/// Only used for diagnostics.
133134
struct BaseError<'a> {
134135
msg: String,
135136
fallback_label: String,
@@ -313,7 +314,7 @@ impl<'a: 'ast, 'ast> LateResolutionVisitor<'a, '_, 'ast> {
313314
}
314315

315316
self.suggest_type_ascription(&mut err, source, path, res, span, &base_error);
316-
self.add_err_code_cases(&mut err, source, path, span);
317+
self.err_code_special_cases(&mut err, source, path, span);
317318

318319
(err, candidates)
319320
}
@@ -667,7 +668,7 @@ impl<'a: 'ast, 'ast> LateResolutionVisitor<'a, '_, 'ast> {
667668
}
668669
}
669670

670-
fn add_err_code_cases(
671+
fn err_code_special_cases(
671672
&mut self,
672673
err: &mut DiagnosticBuilder<'_, ErrorGuaranteed>,
673674
source: PathSource<'_>,

0 commit comments

Comments
 (0)