summary refs log tree commit diff
path: root/compiler/rustc_trait_selection/src
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2022-07-16 08:48:36 +0000
committerbors <bors@rust-lang.org>2022-07-16 08:48:36 +0000
commite092d0b6b43f2de967af0887873151bb1c0b18d3 (patch)
tree3c0903d6cb6800cbf43017141fc38b669a360386 /compiler/rustc_trait_selection/src
parenta8314ef7d0ec7b75c336af2c9857bfaf43002bfc (diff)
parent647922f9d8a6f1fa639ab206e60a76d43cc9d3dd (diff)
downloadrust-1.62.1.tar.gz
rust-1.62.1.zip
Auto merge of #99299 - Mark-Simulacrum:stable-next, r=Mark-Simulacrum 1.62.1
[stable] 1.62.1 release

This bundles:

*  Windows: Fallback for overlapped I/O #98950
*  don't succeed evaluate_obligation query if new opaque types were registered #98614
*  Mitigate MMIO stale data vulnerability #98126
*  Return a FxIndexSet in is_late_bound query. #99219

Also bumps the version number to 1.62.1 and includes a short release notes section for the release.

r? `@Mark-Simulacrum`
Diffstat (limited to 'compiler/rustc_trait_selection/src')
-rw-r--r--compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs1
-rw-r--r--compiler/rustc_trait_selection/src/traits/select/mod.rs4
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 d20ba99ebc9..60cb5914dad 100644
--- a/compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs
+++ b/compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs
@@ -761,6 +761,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 1c9f83f8f34..ed4877638bf 100644
--- a/compiler/rustc_trait_selection/src/traits/select/mod.rs
+++ b/compiler/rustc_trait_selection/src/traits/select/mod.rs
@@ -388,6 +388,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)),