File tree 1 file changed +2
-5
lines changed
compiler/rustc_hir_analysis/src/astconv
1 file changed +2
-5
lines changed Original file line number Diff line number Diff line change @@ -219,8 +219,8 @@ impl<'o, 'tcx> dyn AstConv<'tcx> + 'o {
219
219
// So every `Projection` clause is an `Assoc = Foo` bound. `associated_types` contains all associated
220
220
// types's `DefId`, so the following loop removes all the `DefIds` of the associated types that have a
221
221
// corresponding `Projection` clause
222
- for ( projection_bound , span ) in & projection_bounds {
223
- for def_ids in associated_types . values_mut ( ) {
222
+ for def_ids in associated_types . values_mut ( ) {
223
+ for ( projection_bound , span ) in & projection_bounds {
224
224
let def_id = projection_bound. projection_def_id ( ) ;
225
225
def_ids. remove ( & def_id) ;
226
226
if tcx. generics_require_sized_self ( def_id) {
@@ -232,9 +232,6 @@ impl<'o, 'tcx> dyn AstConv<'tcx> + 'o {
232
232
) ;
233
233
}
234
234
}
235
- }
236
-
237
- for def_ids in associated_types. values_mut ( ) {
238
235
// If the associated type has a `where Self: Sized` bound, we do not need to constrain the associated
239
236
// type in the `dyn Trait`.
240
237
def_ids. retain ( |def_id| !tcx. generics_require_sized_self ( def_id) ) ;
You can’t perform that action at this time.
0 commit comments