Rollup merge of #102016 - lcnr:given-OutlivesEnvironment, r=jackh726
implied_bounds: deal with inference vars fixes #101951 while computing implied bounds for `<<T as ConstructionFirm>::Builder as BuilderFn<'_>>::Output` normalization replaces a projection with an inference var (adding a `Projection` obligation). Until we prove that obligation, this inference var remains unknown, which caused us to miss an implied bound necessary to prove that the unnormalized projection from the trait method signature is wf. r? types
This commit is contained in:
commit
16de1fddee
5 changed files with 91 additions and 34 deletions
|
@ -53,6 +53,7 @@ pub struct OutlivesEnvironment<'tcx> {
|
|||
}
|
||||
|
||||
/// Builder of OutlivesEnvironment.
|
||||
#[derive(Debug)]
|
||||
struct OutlivesEnvironmentBuilder<'tcx> {
|
||||
param_env: ty::ParamEnv<'tcx>,
|
||||
region_relation: TransitiveRelationBuilder<Region<'tcx>>,
|
||||
|
@ -109,6 +110,7 @@ impl<'tcx> OutlivesEnvironment<'tcx> {
|
|||
|
||||
impl<'a, 'tcx> OutlivesEnvironmentBuilder<'tcx> {
|
||||
#[inline]
|
||||
#[instrument(level = "debug")]
|
||||
fn build(self) -> OutlivesEnvironment<'tcx> {
|
||||
OutlivesEnvironment {
|
||||
param_env: self.param_env,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue