@@ -57,14 +57,6 @@ impl OptimizeAttr {
57
57
}
58
58
}
59
59
60
- #[ derive( Clone , Debug , Encodable , Decodable , HashStable_Generic , PrintAttribute ) ]
61
- pub enum DiagnosticAttribute {
62
- // tidy-alphabetical-start
63
- DoNotRecommend ,
64
- OnUnimplemented ,
65
- // tidy-alphabetical-end
66
- }
67
-
68
60
#[ derive( PartialEq , Debug , Encodable , Decodable , Copy , Clone , HashStable_Generic , PrintAttribute ) ]
69
61
pub enum ReprAttr {
70
62
ReprInt ( IntType ) ,
@@ -160,37 +152,49 @@ impl Deprecation {
160
152
#[ derive( Clone , Debug , HashStable_Generic , Encodable , Decodable , PrintAttribute ) ]
161
153
pub enum AttributeKind {
162
154
// tidy-alphabetical-start
155
+ /// Represents `#[rustc_allow_const_fn_unstable]`.
163
156
AllowConstFnUnstable ( ThinVec < Symbol > ) ,
157
+
158
+ /// Represents `#[allow_internal_unstable]`.
164
159
AllowInternalUnstable ( ThinVec < ( Symbol , Span ) > ) ,
160
+
161
+ /// Represents `#[rustc_default_body_unstable]`.
165
162
BodyStability {
166
163
stability : DefaultBodyStability ,
167
164
/// Span of the `#[rustc_default_body_unstable(...)]` attribute
168
165
span : Span ,
169
166
} ,
167
+
168
+ /// Represents `#[rustc_confusables]`.
170
169
Confusables {
171
170
symbols : ThinVec < Symbol > ,
172
171
// FIXME(jdonszelmann): remove when target validation code is moved
173
172
first_span : Span ,
174
173
} ,
174
+
175
+ /// Represents `#[rustc_const_stable]` and `#[rustc_const_unstable]`.
175
176
ConstStability {
176
177
stability : PartialConstStability ,
177
178
/// Span of the `#[rustc_const_stable(...)]` or `#[rustc_const_unstable(...)]` attribute
178
179
span : Span ,
179
180
} ,
181
+
182
+ /// Represents `#[rustc_const_stable_indirect]`.
180
183
ConstStabilityIndirect ,
181
- Deprecation {
182
- deprecation : Deprecation ,
183
- span : Span ,
184
- } ,
185
- Diagnostic ( DiagnosticAttribute ) ,
186
- DocComment {
187
- style : AttrStyle ,
188
- kind : CommentKind ,
189
- span : Span ,
190
- comment : Symbol ,
191
- } ,
184
+
185
+ /// Represents [`#[deprecated]`](https://doc.rust-lang.org/stable/reference/attributes/diagnostics.html#the-deprecated-attribute).
186
+ Deprecation { deprecation : Deprecation , span : Span } ,
187
+
188
+ /// Represents [`#[doc]`](https://doc.rust-lang.org/stable/rustdoc/write-documentation/the-doc-attribute.html).
189
+ DocComment { style : AttrStyle , kind : CommentKind , span : Span , comment : Symbol } ,
190
+
191
+ /// Represents `#[rustc_macro_transparency]`.
192
192
MacroTransparency ( Transparency ) ,
193
+
194
+ /// Represents [`#[repr]`](https://doc.rust-lang.org/stable/reference/type-layout.html#representations).
193
195
Repr ( ThinVec < ( ReprAttr , Span ) > ) ,
196
+
197
+ /// Represents `#[stable]` and `#[unstable]`.
194
198
Stability {
195
199
stability : Stability ,
196
200
/// Span of the `#[stable(...)]` or `#[unstable(...)]` attribute
0 commit comments