From 009db53e49923ced9f7b0dcbc58da47afb031177 Mon Sep 17 00:00:00 2001 From: lcnr Date: Fri, 25 Apr 2025 17:59:33 +0000 Subject: handle specialization in the new trait solver uwu :3 --- compiler/rustc_middle/src/ty/context.rs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'compiler/rustc_middle/src') diff --git a/compiler/rustc_middle/src/ty/context.rs b/compiler/rustc_middle/src/ty/context.rs index 98057a25f04..e8dad1e056c 100644 --- a/compiler/rustc_middle/src/ty/context.rs +++ b/compiler/rustc_middle/src/ty/context.rs @@ -590,6 +590,10 @@ impl<'tcx> Interner for TyCtxt<'tcx> { self.defaultness(def_id).has_value() } + fn impl_specializes(self, impl_def_id: Self::DefId, victim_def_id: Self::DefId) -> bool { + self.specializes((impl_def_id, victim_def_id)) + } + fn impl_is_default(self, impl_def_id: DefId) -> bool { self.defaultness(impl_def_id).is_default() } -- cgit 1.4.1-3-g733a5