diff options
| author | Nicholas Nethercote <n.nethercote@gmail.com> | 2024-02-29 11:58:51 +1100 |
|---|---|---|
| committer | Nicholas Nethercote <n.nethercote@gmail.com> | 2024-03-05 12:14:49 +1100 |
| commit | dc37dddeb5b7d0f4f602d3a4b875beb7188ddc23 (patch) | |
| tree | 8d6a0fe0028ea88f97df9624de8b0bf7cd8b6c96 | |
| parent | b74b4b09d118aed77d41387642d4f7b7b6b4c487 (diff) | |
| download | rust-dc37dddeb5b7d0f4f602d3a4b875beb7188ddc23.tar.gz rust-dc37dddeb5b7d0f4f602d3a4b875beb7188ddc23.zip | |
Rename `DiagnosticMessage` as `DiagMessage`.
| -rw-r--r-- | tests/ui-internal/disallow_span_lint.rs | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/tests/ui-internal/disallow_span_lint.rs b/tests/ui-internal/disallow_span_lint.rs index b9b4a07d29d..c5029bbd9a4 100644 --- a/tests/ui-internal/disallow_span_lint.rs +++ b/tests/ui-internal/disallow_span_lint.rs @@ -5,12 +5,17 @@ extern crate rustc_hir; extern crate rustc_lint; extern crate rustc_middle; -use rustc_errors::{DiagnosticMessage, MultiSpan}; +use rustc_errors::{DiagMessage, MultiSpan}; use rustc_hir::hir_id::HirId; use rustc_lint::{Lint, LintContext}; use rustc_middle::ty::TyCtxt; -pub fn a(cx: impl LintContext, lint: &'static Lint, span: impl Into<MultiSpan>, msg: impl Into<DiagnosticMessage>) { +pub fn a( + cx: impl LintContext, + lint: &'static Lint, + span: impl Into<MultiSpan>, + msg: impl Into<DiagMessage>) +{ cx.span_lint(lint, span, msg, |_| {}); } @@ -19,7 +24,7 @@ pub fn b( lint: &'static Lint, hir_id: HirId, span: impl Into<MultiSpan>, - msg: impl Into<DiagnosticMessage>, + msg: impl Into<DiagMessage>, ) { tcx.node_span_lint(lint, hir_id, span, msg, |_| {}); } |
