From eb0afe1845c970f6dd16bc53fa7f3464ee76daff Mon Sep 17 00:00:00 2001 From: varkor Date: Thu, 30 May 2019 23:43:04 +0100 Subject: [PATCH] Add more information in ConstEvalFailure error --- src/librustc/traits/error_reporting.rs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/librustc/traits/error_reporting.rs b/src/librustc/traits/error_reporting.rs index a29b173880a..95312d55b3b 100644 --- a/src/librustc/traits/error_reporting.rs +++ b/src/librustc/traits/error_reporting.rs @@ -914,8 +914,11 @@ impl<'a, 'gcx, 'tcx> InferCtxt<'a, 'gcx, 'tcx> { } // already reported in the query - ConstEvalFailure(_) => { - self.tcx.sess.delay_span_bug(span, "constant in type had an ignored error"); + ConstEvalFailure(err) => { + self.tcx.sess.delay_span_bug( + span, + &format!("constant in type had an ignored error: {:?}", err), + ); return; }