@@ -89,31 +89,31 @@ pub(crate) struct TransientMutBorrowErrRaw {
89
89
}
90
90
91
91
#[ derive( SessionDiagnostic ) ]
92
- #[ error ( const_eval:: max_num_nodes_in_const) ]
92
+ #[ diag ( const_eval:: max_num_nodes_in_const) ]
93
93
pub ( crate ) struct MaxNumNodesInConstErr {
94
94
#[ primary_span]
95
95
pub span : Span ,
96
96
pub s : String ,
97
97
}
98
98
99
99
#[ derive( SessionDiagnostic ) ]
100
- #[ error ( const_eval:: unallowed_fn_pointer_call) ]
100
+ #[ diag ( const_eval:: unallowed_fn_pointer_call) ]
101
101
pub ( crate ) struct UnallowedFnPointerCall {
102
102
#[ primary_span]
103
103
pub span : Span ,
104
104
pub kind : ConstContext ,
105
105
}
106
106
107
107
#[ derive( SessionDiagnostic ) ]
108
- #[ error ( const_eval:: unstable_const_fn) ]
108
+ #[ diag ( const_eval:: unstable_const_fn) ]
109
109
pub ( crate ) struct UnstableConstFn {
110
110
#[ primary_span]
111
111
pub span : Span ,
112
112
pub def_path : String ,
113
113
}
114
114
115
115
#[ derive( SessionDiagnostic ) ]
116
- #[ error ( const_eval:: unallowed_mutable_refs, code = "E0764" ) ]
116
+ #[ diag ( const_eval:: unallowed_mutable_refs, code = "E0764" ) ]
117
117
pub ( crate ) struct UnallowedMutableRefs {
118
118
#[ primary_span]
119
119
pub span : Span ,
@@ -123,7 +123,7 @@ pub(crate) struct UnallowedMutableRefs {
123
123
}
124
124
125
125
#[ derive( SessionDiagnostic ) ]
126
- #[ error ( const_eval:: unallowed_mutable_refs_raw, code = "E0764" ) ]
126
+ #[ diag ( const_eval:: unallowed_mutable_refs_raw, code = "E0764" ) ]
127
127
pub ( crate ) struct UnallowedMutableRefsRaw {
128
128
#[ primary_span]
129
129
pub span : Span ,
@@ -132,15 +132,15 @@ pub(crate) struct UnallowedMutableRefsRaw {
132
132
pub teach : Option < ( ) > ,
133
133
}
134
134
#[ derive( SessionDiagnostic ) ]
135
- #[ error ( const_eval:: non_const_fmt_macro_call, code = "E0015" ) ]
135
+ #[ diag ( const_eval:: non_const_fmt_macro_call, code = "E0015" ) ]
136
136
pub ( crate ) struct NonConstFmtMacroCall {
137
137
#[ primary_span]
138
138
pub span : Span ,
139
139
pub kind : ConstContext ,
140
140
}
141
141
142
142
#[ derive( SessionDiagnostic ) ]
143
- #[ error ( const_eval:: non_const_fn_call, code = "E0015" ) ]
143
+ #[ diag ( const_eval:: non_const_fn_call, code = "E0015" ) ]
144
144
pub ( crate ) struct NonConstFnCall {
145
145
#[ primary_span]
146
146
pub span : Span ,
@@ -149,15 +149,15 @@ pub(crate) struct NonConstFnCall {
149
149
}
150
150
151
151
#[ derive( SessionDiagnostic ) ]
152
- #[ error ( const_eval:: unallowed_op_in_const_context) ]
152
+ #[ diag ( const_eval:: unallowed_op_in_const_context) ]
153
153
pub ( crate ) struct UnallowedOpInConstContext {
154
154
#[ primary_span]
155
155
pub span : Span ,
156
156
pub msg : String ,
157
157
}
158
158
159
159
#[ derive( SessionDiagnostic ) ]
160
- #[ error ( const_eval:: unallowed_heap_allocations, code = "E0010" ) ]
160
+ #[ diag ( const_eval:: unallowed_heap_allocations, code = "E0010" ) ]
161
161
pub ( crate ) struct UnallowedHeapAllocations {
162
162
#[ primary_span]
163
163
#[ label]
@@ -168,15 +168,15 @@ pub(crate) struct UnallowedHeapAllocations {
168
168
}
169
169
170
170
#[ derive( SessionDiagnostic ) ]
171
- #[ error ( const_eval:: unallowed_inline_asm, code = "E0015" ) ]
171
+ #[ diag ( const_eval:: unallowed_inline_asm, code = "E0015" ) ]
172
172
pub ( crate ) struct UnallowedInlineAsm {
173
173
#[ primary_span]
174
174
pub span : Span ,
175
175
pub kind : ConstContext ,
176
176
}
177
177
178
178
#[ derive( SessionDiagnostic ) ]
179
- #[ error ( const_eval:: interior_mutable_data_refer, code = "E0492" ) ]
179
+ #[ diag ( const_eval:: interior_mutable_data_refer, code = "E0492" ) ]
180
180
pub ( crate ) struct InteriorMutableDataRefer {
181
181
#[ primary_span]
182
182
#[ label]
@@ -189,7 +189,7 @@ pub(crate) struct InteriorMutableDataRefer {
189
189
}
190
190
191
191
#[ derive( SessionDiagnostic ) ]
192
- #[ error ( const_eval:: interior_mutability_borrow) ]
192
+ #[ diag ( const_eval:: interior_mutability_borrow) ]
193
193
pub ( crate ) struct InteriorMutabilityBorrow {
194
194
#[ primary_span]
195
195
pub span : Span ,
0 commit comments