about summary refs log tree commit diff
path: root/compiler/rustc_middle/src/ty
diff options
context:
space:
mode:
authorJacob Pratt <jacob@jhpratt.dev>2024-11-20 01:54:27 -0500
committerGitHub <noreply@github.com>2024-11-20 01:54:27 -0500
commitb9cd5eb1906b042dd3785f59c340d8b90ab9e144 (patch)
tree57132fe62426f5a8640bde4d928c1d411b7436dc /compiler/rustc_middle/src/ty
parentcd36973a13f30c552c96884625de192065ed4383 (diff)
parentdef7ed08e7b27288bc861384ec166ebc5a419abc (diff)
downloadrust-b9cd5eb1906b042dd3785f59c340d8b90ab9e144.tar.gz
rust-b9cd5eb1906b042dd3785f59c340d8b90ab9e144.zip
Rollup merge of #133216 - compiler-errors:const-fn, r=lcnr
Implement `~const Fn` trait goal in the new solver

Split out from https://github.com/rust-lang/rust/pull/132329 since this should be easier to review on its own.

r? lcnr
Diffstat (limited to 'compiler/rustc_middle/src/ty')
-rw-r--r--compiler/rustc_middle/src/ty/context.rs6
1 files changed, 5 insertions, 1 deletions
diff --git a/compiler/rustc_middle/src/ty/context.rs b/compiler/rustc_middle/src/ty/context.rs
index 68c3b064eee..ad42eacf823 100644
--- a/compiler/rustc_middle/src/ty/context.rs
+++ b/compiler/rustc_middle/src/ty/context.rs
@@ -376,7 +376,11 @@ impl<'tcx> Interner for TyCtxt<'tcx> {
         self.explicit_implied_predicates_of(def_id).map_bound(|preds| preds.into_iter().copied())
     }
 
-    fn is_const_impl(self, def_id: DefId) -> bool {
+    fn impl_is_const(self, def_id: DefId) -> bool {
+        self.is_conditionally_const(def_id)
+    }
+
+    fn fn_is_const(self, def_id: DefId) -> bool {
         self.is_conditionally_const(def_id)
     }