File tree 1 file changed +3
-2
lines changed
compiler/rustc_incremental/src/persist
1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -168,7 +168,7 @@ pub fn check_dirty_clean_annotations(tcx: TyCtxt<'_>) {
168
168
// Note that we cannot use the existing "unused attribute"-infrastructure
169
169
// here, since that is running before codegen. This is also the reason why
170
170
// all codegen-specific attributes are `AssumedUsed` in rustc_ast::feature_gate.
171
- all_attrs. report_unchecked_attrs ( & dirty_clean_visitor. checked_attrs ) ;
171
+ all_attrs. report_unchecked_attrs ( dirty_clean_visitor. checked_attrs ) ;
172
172
} )
173
173
}
174
174
@@ -535,13 +535,14 @@ impl FindAllAttrs<'_, 'tcx> {
535
535
false
536
536
}
537
537
538
- fn report_unchecked_attrs ( & self , checked_attrs : & FxHashSet < ast:: AttrId > ) {
538
+ fn report_unchecked_attrs ( & self , mut checked_attrs : FxHashSet < ast:: AttrId > ) {
539
539
for attr in & self . found_attrs {
540
540
if !checked_attrs. contains ( & attr. id ) {
541
541
self . tcx . sess . span_err (
542
542
attr. span ,
543
543
"found unchecked `#[rustc_dirty]` / `#[rustc_clean]` attribute" ,
544
544
) ;
545
+ checked_attrs. insert ( attr. id ) ;
545
546
}
546
547
}
547
548
}
You can’t perform that action at this time.
0 commit comments