@@ -181,8 +181,6 @@ pub struct Validator<'mir, 'tcx> {
181
181
/// The span of the current statement.
182
182
span : Span ,
183
183
184
- const_checking_stopped : bool ,
185
-
186
184
error_emitted : bool ,
187
185
secondary_errors : Vec < Diagnostic > ,
188
186
}
@@ -201,7 +199,6 @@ impl Validator<'mir, 'tcx> {
201
199
span : ccx. body . span ,
202
200
ccx,
203
201
qualifs : Default :: default ( ) ,
204
- const_checking_stopped : false ,
205
202
error_emitted : false ,
206
203
secondary_errors : Vec :: new ( ) ,
207
204
}
@@ -289,12 +286,6 @@ impl Validator<'mir, 'tcx> {
289
286
/// Emits an error at the given `span` if an expression cannot be evaluated in the current
290
287
/// context.
291
288
pub fn check_op_spanned < O : NonConstOp > ( & mut self , op : O , span : Span ) {
292
- // HACK: This is for strict equivalence with the old `qualify_min_const_fn` pass, which
293
- // only emitted one error per function. It should be removed and the test output updated.
294
- if self . const_checking_stopped {
295
- return ;
296
- }
297
-
298
289
let gate = match op. status_in_item ( self . ccx ) {
299
290
Status :: Allowed => return ,
300
291
@@ -328,10 +319,6 @@ impl Validator<'mir, 'tcx> {
328
319
329
320
ops:: DiagnosticImportance :: Secondary => err. buffer ( & mut self . secondary_errors ) ,
330
321
}
331
-
332
- if O :: STOPS_CONST_CHECKING {
333
- self . const_checking_stopped = true ;
334
- }
335
322
}
336
323
337
324
fn check_static ( & mut self , def_id : DefId , span : Span ) {
0 commit comments