about summary refs log tree commit diff
path: root/compiler/rustc_infer/src
diff options
context:
space:
mode:
authorMichael Goulet <michael@errs.io>2024-07-22 13:54:48 -0400
committerMichael Goulet <michael@errs.io>2024-07-22 13:54:48 -0400
commit7bca516b357f5cf596250f99353a08f65cb0456a (patch)
tree48b65707eef9466262fa97a1ad5b841e993ca7df /compiler/rustc_infer/src
parent20f23abbecd7ac5e04dd7ccadc29c3824e28a269 (diff)
downloadrust-7bca516b357f5cf596250f99353a08f65cb0456a.tar.gz
rust-7bca516b357f5cf596250f99353a08f65cb0456a.zip
Get rid of can_eq_shallow
Diffstat (limited to 'compiler/rustc_infer/src')
-rw-r--r--compiler/rustc_infer/src/infer/mod.rs12
1 files changed, 0 insertions, 12 deletions
diff --git a/compiler/rustc_infer/src/infer/mod.rs b/compiler/rustc_infer/src/infer/mod.rs
index 7fc4e36d752..3cee0a622f1 100644
--- a/compiler/rustc_infer/src/infer/mod.rs
+++ b/compiler/rustc_infer/src/infer/mod.rs
@@ -755,18 +755,6 @@ impl<'tcx> InferCtxt<'tcx> {
             .collect()
     }
 
-    // FIXME(-Znext-solver): Get rid of this method, it's never correct. Either that,
-    // or we need to process the obligations.
-    pub fn can_eq_shallow<T>(&self, param_env: ty::ParamEnv<'tcx>, a: T, b: T) -> bool
-    where
-        T: at::ToTrace<'tcx>,
-    {
-        let origin = &ObligationCause::dummy();
-        // We're only answering whether the types could be the same, and with
-        // opaque types, "they can be the same", via registering a hidden type.
-        self.probe(|_| self.at(origin, param_env).eq(DefineOpaqueTypes::Yes, a, b).is_ok())
-    }
-
     #[instrument(skip(self), level = "debug")]
     pub fn sub_regions(
         &self,