From 28ce5883210da1ed90cda9b7da3d0b16e2794e69 Mon Sep 17 00:00:00 2001 From: Michael Goulet Date: Mon, 20 May 2024 12:57:07 -0400 Subject: Uplift binder --- compiler/rustc_errors/src/diagnostic_impls.rs | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'compiler/rustc_errors/src') diff --git a/compiler/rustc_errors/src/diagnostic_impls.rs b/compiler/rustc_errors/src/diagnostic_impls.rs index 4bf7dccab92..9614f4e80e1 100644 --- a/compiler/rustc_errors/src/diagnostic_impls.rs +++ b/compiler/rustc_errors/src/diagnostic_impls.rs @@ -118,6 +118,15 @@ impl IntoDiagArg for rustc_type_ir::FnSig { } } +impl IntoDiagArg for rustc_type_ir::Binder +where + T: IntoDiagArg, +{ + fn into_diag_arg(self) -> DiagArgValue { + self.skip_binder().into_diag_arg() + } +} + into_diag_arg_for_number!(i8, u8, i16, u16, i32, u32, i64, u64, i128, u128, isize, usize); impl IntoDiagArg for bool { -- cgit 1.4.1-3-g733a5