File tree Expand file tree Collapse file tree 1 file changed +4
-7
lines changed
compiler/rustc_trait_selection/src/traits/query/type_op Expand file tree Collapse file tree 1 file changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -20,14 +20,11 @@ impl<'tcx> super::QueryTypeOp<'tcx> for ProvePredicate<'tcx> {
2020 // such cases.
2121 if let ty:: PredicateKind :: Clause ( ty:: ClauseKind :: Trait ( trait_ref) ) =
2222 key. value . predicate . kind ( ) . skip_binder ( )
23+ && let Some ( sized_def_id) = tcx. lang_items ( ) . sized_trait ( )
24+ && trait_ref. def_id ( ) == sized_def_id
25+ && trait_ref. self_ty ( ) . is_trivially_sized ( tcx)
2326 {
24- if let Some ( sized_def_id) = tcx. lang_items ( ) . sized_trait ( ) {
25- if trait_ref. def_id ( ) == sized_def_id {
26- if trait_ref. self_ty ( ) . is_trivially_sized ( tcx) {
27- return Some ( ( ) ) ;
28- }
29- }
30- }
27+ return Some ( ( ) ) ;
3128 }
3229
3330 if let ty:: PredicateKind :: Clause ( ty:: ClauseKind :: WellFormed ( arg) ) =
You can’t perform that action at this time.
0 commit comments