tolerate region vars in implied bounds
See https://github.com/rust-lang/rust/issues/109628.
This commit is contained in:
parent
b20aa97d48
commit
2a3177a8bc
2 changed files with 28 additions and 1 deletions
|
@ -142,7 +142,10 @@ impl<'tcx> OutlivesEnvironmentBuilder<'tcx> {
|
|||
ty::ReStatic | ty::ReEarlyBound(_) | ty::ReFree(_),
|
||||
) => self.region_relation.add(r_a, r_b),
|
||||
(ty::ReError(_), _) | (_, ty::ReError(_)) => {}
|
||||
_ => bug!("add_outlives_bounds: unexpected regions"),
|
||||
// FIXME(#109628): We shouldn't have existential variables in implied bounds.
|
||||
// Panic here once the linked issue is resolved!
|
||||
(ty::ReVar(_), _) | (_, ty::ReVar(_)) => {}
|
||||
_ => bug!("add_outlives_bounds: unexpected regions: ({r_a:?}, {r_b:?})"),
|
||||
},
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue