diff options
| author | varkor <github@varkor.com> | 2019-05-30 23:43:04 +0100 |
|---|---|---|
| committer | varkor <github@varkor.com> | 2019-05-31 01:19:59 +0100 |
| commit | eb0afe1845c970f6dd16bc53fa7f3464ee76daff (patch) | |
| tree | c95ac9fb80bca0e2c1834af71bdafeeee04ea321 | |
| parent | 0bfbaa6e8dfb509b453020740fd37c7a22882c87 (diff) | |
| download | rust-eb0afe1845c970f6dd16bc53fa7f3464ee76daff.tar.gz rust-eb0afe1845c970f6dd16bc53fa7f3464ee76daff.zip | |
Add more information in ConstEvalFailure error
| -rw-r--r-- | src/librustc/traits/error_reporting.rs | 7 |
1 files 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; } |
