diff options
| author | bors <bors@rust-lang.org> | 2022-07-10 01:19:06 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2022-07-10 01:19:06 +0000 |
| commit | 93ef0cd7fd86d3d05cee131070a8a2cb45f3efab (patch) | |
| tree | fffd78376164d90a656f80614e34794ec671c161 /compiler/rustc_trait_selection/src | |
| parent | 94811fdc269d23dd9f1dff88f165bc2d6f5f85d4 (diff) | |
| parent | b5c69118d3f2ef5e2c27a608385dd10c7302cd70 (diff) | |
| download | rust-93ef0cd7fd86d3d05cee131070a8a2cb45f3efab.tar.gz rust-93ef0cd7fd86d3d05cee131070a8a2cb45f3efab.zip | |
Auto merge of #99098 - Mark-Simulacrum:beta-next, r=Mark-Simulacrum
[beta] backport rollup * Return a FxIndexSet in is_late_bound query. #98959 * rustdoc: filter '_ lifetimes from ty::PolyTraitRef #98727 * don't succeed evaluate_obligation query if new opaque types were registered #98614 * Update llvm-project #98567 There's a few more as-yet-unapproved/unmerged PRs that'll land later, but creating a partial rollup for now so that we can include at least some PRs in the first crater run. r? `@Mark-Simulacrum`
Diffstat (limited to 'compiler/rustc_trait_selection/src')
| -rw-r--r-- | compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs | 1 | ||||
| -rw-r--r-- | compiler/rustc_trait_selection/src/traits/select/mod.rs | 4 |
2 files changed, 5 insertions, 0 deletions
diff --git a/compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs b/compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs index fbe66d7dcdd..6c91aa1556d 100644 --- a/compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs +++ b/compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs @@ -777,6 +777,7 @@ impl<'a, 'tcx> InferCtxtExt<'tcx> for InferCtxt<'a, 'tcx> { Ok( EvaluationResult::EvaluatedToOk | EvaluationResult::EvaluatedToOkModuloRegions + | EvaluationResult::EvaluatedToOkModuloOpaqueTypes | EvaluationResult::EvaluatedToAmbig, ) => {} _ => return false, diff --git a/compiler/rustc_trait_selection/src/traits/select/mod.rs b/compiler/rustc_trait_selection/src/traits/select/mod.rs index 297fbfa1c32..2641faff80f 100644 --- a/compiler/rustc_trait_selection/src/traits/select/mod.rs +++ b/compiler/rustc_trait_selection/src/traits/select/mod.rs @@ -394,6 +394,10 @@ impl<'cx, 'tcx> SelectionContext<'cx, 'tcx> { Err(_) => return Ok(EvaluatedToErr), } + if self.infcx.opaque_types_added_in_snapshot(snapshot) { + return Ok(result.max(EvaluatedToOkModuloOpaqueTypes)); + } + match self.infcx.region_constraints_added_in_snapshot(snapshot) { None => Ok(result), Some(_) => Ok(result.max(EvaluatedToOkModuloRegions)), |
