File tree Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -1228,6 +1228,10 @@ impl<'o, 'tcx> dyn AstConv<'tcx> + 'o {
1228
1228
trait_ref : ty:: TraitRef < ' tcx > ,
1229
1229
) -> ty:: ExistentialTraitRef < ' tcx > {
1230
1230
if trait_ref. self_ty ( ) != self . tcx ( ) . types . trait_object_dummy_self {
1231
+ // FIXME: There appears to be a missing filter on top of `expand_trait_aliases`, which
1232
+ // picks up non-supertraits where clauses - but also, the object safety completely
1233
+ // ignores trait aliases, which could be object safety hazards. We `delay_span_bug`
1234
+ // here to avoid an ICE in stable even when the feature is disabled. (#66420)
1231
1235
self . tcx ( ) . sess . delay_span_bug ( DUMMY_SP , & format ! (
1232
1236
"trait_ref_to_existential called on {:?} with non-dummy Self" ,
1233
1237
trait_ref,
Original file line number Diff line number Diff line change 1
- #![ feature( trait_alias) ]
1
+ #![ feature( trait_alias) ] // Enabled to reduce stderr output, but can be triggered even if disabled.
2
2
trait Trait { }
3
3
trait WithType {
4
4
type Ctx ;
You can’t perform that action at this time.
0 commit comments