@@ -98,7 +98,6 @@ mod outlives;
98
98
pub mod structured_errors;
99
99
mod variance;
100
100
101
- use rustc_errors:: ErrorGuaranteed ;
102
101
use rustc_hir as hir;
103
102
use rustc_middle:: middle;
104
103
use rustc_middle:: query:: Providers ;
@@ -156,11 +155,11 @@ pub fn provide(providers: &mut Providers) {
156
155
hir_wf_check:: provide ( providers) ;
157
156
}
158
157
159
- pub fn check_crate ( tcx : TyCtxt < ' _ > ) -> Result < ( ) , ErrorGuaranteed > {
158
+ pub fn check_crate ( tcx : TyCtxt < ' _ > ) {
160
159
let _prof_timer = tcx. sess . timer ( "type_check_crate" ) ;
161
160
162
161
if tcx. features ( ) . rustc_attrs {
163
- tcx. sess . time ( "outlives_testing" , || outlives:: test:: test_inferred_outlives ( tcx) ) ? ;
162
+ tcx. sess . time ( "outlives_testing" , || outlives:: test:: test_inferred_outlives ( tcx) ) ;
164
163
}
165
164
166
165
tcx. sess . time ( "coherence_checking" , || {
@@ -177,11 +176,11 @@ pub fn check_crate(tcx: TyCtxt<'_>) -> Result<(), ErrorGuaranteed> {
177
176
} ) ;
178
177
179
178
if tcx. features ( ) . rustc_attrs {
180
- tcx. sess . time ( "variance_testing" , || variance:: test:: test_variance ( tcx) ) ? ;
179
+ tcx. sess . time ( "variance_testing" , || variance:: test:: test_variance ( tcx) ) ;
181
180
}
182
181
183
182
if tcx. features ( ) . rustc_attrs {
184
- collect:: test_opaque_hidden_types ( tcx) ? ;
183
+ collect:: test_opaque_hidden_types ( tcx) ;
185
184
}
186
185
187
186
// Make sure we evaluate all static and (non-associated) const items, even if unused.
@@ -211,8 +210,6 @@ pub fn check_crate(tcx: TyCtxt<'_>) -> Result<(), ErrorGuaranteed> {
211
210
} ) ;
212
211
213
212
tcx. ensure ( ) . check_unused_traits ( ( ) ) ;
214
-
215
- Ok ( ( ) )
216
213
}
217
214
218
215
/// A quasi-deprecated helper used in rustdoc and clippy to get
0 commit comments