about summary refs log tree commit diff
path: root/compiler/rustc_next_trait_solver/src/solve/mod.rs
diff options
context:
space:
mode:
authorLukas Markeffsky <@>2025-01-27 04:30:00 +0100
committerLukas Markeffsky <@>2025-01-30 17:47:44 +0100
commit10fc0b159ee6e5281bf38f65680082961dd7bec3 (patch)
tree9abdb74a542fbec70d97e48b43e660bb01793eac /compiler/rustc_next_trait_solver/src/solve/mod.rs
parent5a45ab9738330fb317d49e3594c2db5248b1e971 (diff)
downloadrust-10fc0b159ee6e5281bf38f65680082961dd7bec3.tar.gz
rust-10fc0b159ee6e5281bf38f65680082961dd7bec3.zip
introduce `ty::Value`
Co-authored-by: FedericoBruzzone <federico.bruzzone.i@gmail.com>
Diffstat (limited to 'compiler/rustc_next_trait_solver/src/solve/mod.rs')
-rw-r--r--compiler/rustc_next_trait_solver/src/solve/mod.rs6
1 files changed, 2 insertions, 4 deletions
diff --git a/compiler/rustc_next_trait_solver/src/solve/mod.rs b/compiler/rustc_next_trait_solver/src/solve/mod.rs
index 8d1194ee539..1fa35b60304 100644
--- a/compiler/rustc_next_trait_solver/src/solve/mod.rs
+++ b/compiler/rustc_next_trait_solver/src/solve/mod.rs
@@ -160,9 +160,7 @@ where
             ty::ConstKind::Infer(_) => {
                 self.evaluate_added_goals_and_make_canonical_response(Certainty::AMBIGUOUS)
             }
-            ty::ConstKind::Placeholder(_)
-            | ty::ConstKind::Value(_, _)
-            | ty::ConstKind::Error(_) => {
+            ty::ConstKind::Placeholder(_) | ty::ConstKind::Value(_) | ty::ConstKind::Error(_) => {
                 self.evaluate_added_goals_and_make_canonical_response(Certainty::Yes)
             }
             // We can freely ICE here as:
@@ -199,7 +197,7 @@ where
                 unreachable!("`ConstKind::Param` should have been canonicalized to `Placeholder`")
             }
             ty::ConstKind::Bound(_, _) => panic!("escaping bound vars in {:?}", ct),
-            ty::ConstKind::Value(ty, _) => ty,
+            ty::ConstKind::Value(cv) => cv.ty(),
             ty::ConstKind::Placeholder(placeholder) => {
                 self.cx().find_const_ty_from_env(goal.param_env, placeholder)
             }