Skip to content

Commit 8197991

Browse files
committed
Rename LintLevelsBuilder::struct_lint as LintLevelsBuilder::opt_span_lint.
1 parent 75bf1ee commit 8197991

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

compiler/rustc_lint/src/context.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -700,7 +700,7 @@ impl LintContext for EarlyContext<'_> {
700700
msg: impl Into<DiagnosticMessage>,
701701
decorate: impl for<'a, 'b> FnOnce(&'b mut DiagnosticBuilder<'a, ()>),
702702
) {
703-
self.builder.struct_lint(lint, span.map(|s| s.into()), msg, decorate)
703+
self.builder.opt_span_lint(lint, span.map(|s| s.into()), msg, decorate)
704704
}
705705

706706
fn get_lint_level(&self, lint: &'static Lint) -> Level {

compiler/rustc_lint/src/levels.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1099,7 +1099,7 @@ impl<'s, P: LintLevelsProvider> LintLevelsBuilder<'s, P> {
10991099
/// [`struct_lint_level`]: rustc_middle::lint::struct_lint_level#decorate-signature
11001100
#[rustc_lint_diagnostics]
11011101
#[track_caller]
1102-
pub(crate) fn struct_lint(
1102+
pub(crate) fn opt_span_lint(
11031103
&self,
11041104
lint: &'static Lint,
11051105
span: Option<MultiSpan>,

compiler/rustc_trait_selection/src/traits/specialize/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -387,7 +387,7 @@ fn report_conflicting_impls<'tcx>(
387387
let impl_span = tcx.def_span(impl_def_id);
388388

389389
// Work to be done after we've built the DiagnosticBuilder. We have to define it
390-
// now because the struct_lint methods don't return back the DiagnosticBuilder
390+
// now because the lint emit methods don't return back the DiagnosticBuilder
391391
// that's passed in.
392392
fn decorate<'tcx>(
393393
tcx: TyCtxt<'tcx>,

0 commit comments

Comments
 (0)