1
Fork 0

UPDATE - rename DiagnosticHandler macro to Diagnostic

This commit is contained in:
Jhonny Bill Mena 2022-09-18 11:46:56 -04:00
parent 191fac6826
commit a3396b2070
34 changed files with 484 additions and 484 deletions

View file

@ -1,8 +1,8 @@
use rustc_errors::DiagnosticArgFromDisplay;
use rustc_macros::{DiagnosticHandler, LintDiagnostic, SessionSubdiagnostic};
use rustc_macros::{Diagnostic, LintDiagnostic, SessionSubdiagnostic};
use rustc_span::{Span, Symbol};
#[derive(DiagnosticHandler)]
#[derive(Diagnostic)]
#[diag(privacy::field_is_private, code = "E0451")]
pub struct FieldIsPrivate {
#[primary_span]
@ -29,7 +29,7 @@ pub enum FieldIsPrivateLabel {
},
}
#[derive(DiagnosticHandler)]
#[derive(Diagnostic)]
#[diag(privacy::item_is_private)]
pub struct ItemIsPrivate<'a> {
#[primary_span]
@ -39,7 +39,7 @@ pub struct ItemIsPrivate<'a> {
pub descr: DiagnosticArgFromDisplay<'a>,
}
#[derive(DiagnosticHandler)]
#[derive(Diagnostic)]
#[diag(privacy::unnamed_item_is_private)]
pub struct UnnamedItemIsPrivate {
#[primary_span]
@ -48,7 +48,7 @@ pub struct UnnamedItemIsPrivate {
}
// Duplicate of `InPublicInterface` but with a different error code, shares the same slug.
#[derive(DiagnosticHandler)]
#[derive(Diagnostic)]
#[diag(privacy::in_public_interface, code = "E0445")]
pub struct InPublicInterfaceTraits<'a> {
#[primary_span]
@ -62,7 +62,7 @@ pub struct InPublicInterfaceTraits<'a> {
}
// Duplicate of `InPublicInterfaceTraits` but with a different error code, shares the same slug.
#[derive(DiagnosticHandler)]
#[derive(Diagnostic)]
#[diag(privacy::in_public_interface, code = "E0446")]
pub struct InPublicInterface<'a> {
#[primary_span]