@@ -4,7 +4,7 @@ use rustc_session::{lint::Level, parse::ParseSess, SessionDiagnostic};
44use rustc_span:: { Span , Symbol } ;
55
66#[ derive( SessionDiagnostic ) ]
7- #[ error ( lint:: overruled_attribute, code = "E0453" ) ]
7+ #[ diag ( lint:: overruled_attribute, code = "E0453" ) ]
88pub struct OverruledAttribute {
99 #[ primary_span]
1010 pub span : Span ,
@@ -43,7 +43,7 @@ impl AddSubdiagnostic for OverruledAttributeSub {
4343}
4444
4545#[ derive( SessionDiagnostic ) ]
46- #[ error ( lint:: malformed_attribute, code = "E0452" ) ]
46+ #[ diag ( lint:: malformed_attribute, code = "E0452" ) ]
4747pub struct MalformedAttribute {
4848 #[ primary_span]
4949 pub span : Span ,
@@ -62,7 +62,7 @@ pub enum MalformedAttributeSub {
6262}
6363
6464#[ derive( SessionDiagnostic ) ]
65- #[ error ( lint:: unknown_tool_in_scoped_lint, code = "E0710" ) ]
65+ #[ diag ( lint:: unknown_tool_in_scoped_lint, code = "E0710" ) ]
6666pub struct UnknownToolInScopedLint {
6767 #[ primary_span]
6868 pub span : Option < Span > ,
@@ -73,7 +73,7 @@ pub struct UnknownToolInScopedLint {
7373}
7474
7575#[ derive( SessionDiagnostic ) ]
76- #[ error ( lint:: builtin_ellipsis_inclusive_range_patterns, code = "E0783" ) ]
76+ #[ diag ( lint:: builtin_ellipsis_inclusive_range_patterns, code = "E0783" ) ]
7777pub struct BuiltinEllpisisInclusiveRangePatterns {
7878 #[ primary_span]
7979 pub span : Span ,
@@ -108,7 +108,7 @@ impl AddSubdiagnostic for RequestedLevel {
108108}
109109
110110#[ derive( SessionDiagnostic ) ]
111- #[ error ( lint:: unsupported_group, code = "E0602" ) ]
111+ #[ diag ( lint:: unsupported_group, code = "E0602" ) ]
112112pub struct UnsupportedGroup {
113113 pub lint_group : String ,
114114}
@@ -137,23 +137,23 @@ impl SessionDiagnostic<'_> for CheckNameUnknown {
137137}
138138
139139#[ derive( SessionDiagnostic ) ]
140- #[ error ( lint:: check_name_unknown_tool, code = "E0602" ) ]
140+ #[ diag ( lint:: check_name_unknown_tool, code = "E0602" ) ]
141141pub struct CheckNameUnknownTool {
142142 pub tool_name : Symbol ,
143143 #[ subdiagnostic]
144144 pub sub : RequestedLevel ,
145145}
146146
147147#[ derive( SessionDiagnostic ) ]
148- #[ warning ( lint:: check_name_warning) ]
148+ #[ diag ( lint:: check_name_warning) ]
149149pub struct CheckNameWarning {
150150 pub msg : String ,
151151 #[ subdiagnostic]
152152 pub sub : RequestedLevel ,
153153}
154154
155155#[ derive( SessionDiagnostic ) ]
156- #[ warning ( lint:: check_name_deprecated) ]
156+ #[ diag ( lint:: check_name_deprecated) ]
157157pub struct CheckNameDeprecated {
158158 pub lint_name : String ,
159159 pub new_name : String ,
0 commit comments