about summary refs log tree commit diff
diff options
context:
space:
mode:
authorNiko Matsakis <niko@alum.mit.edu>2019-01-25 14:54:42 -0500
committerRémy Rakic <remy.rakic@gmail.com>2019-01-27 10:52:44 +0100
commitab80162e3ffe52ded81917b8f0c032c9bc9d3c58 (patch)
tree2a8d791b23bfb8953724747434f63da887e99063
parentc5dea5753fd1c1a77813b7829573025e28c214b5 (diff)
downloadrust-ab80162e3ffe52ded81917b8f0c032c9bc9d3c58.tar.gz
rust-ab80162e3ffe52ded81917b8f0c032c9bc9d3c58.zip
add a lot more `debug!` to `try_report_placeholders_trait`
-rw-r--r--src/librustc/infer/error_reporting/nice_region_error/placeholder_error.rs15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/librustc/infer/error_reporting/nice_region_error/placeholder_error.rs b/src/librustc/infer/error_reporting/nice_region_error/placeholder_error.rs
index b5187d2dbb6..94e20731bfe 100644
--- a/src/librustc/infer/error_reporting/nice_region_error/placeholder_error.rs
+++ b/src/librustc/infer/error_reporting/nice_region_error/placeholder_error.rs
@@ -206,6 +206,15 @@ impl NiceRegionError<'me, 'gcx, 'tcx> {
         expected_substs: &'tcx Substs<'tcx>,
         actual_substs: &'tcx Substs<'tcx>,
     ) -> ErrorReported {
+        debug!("try_report_placeholders_trait(\
+                vid={:?}, \
+                sub_placeholder={:?}, \
+                sup_placeholder={:?}, \
+                trait_def_id={:?}, \
+                expected_substs={:?}, \
+                actual_substs={:?})",
+               vid, sub_placeholder, sup_placeholder, trait_def_id, expected_substs, actual_substs);
+
         let mut err = self.tcx().sess.struct_span_err(
             cause.span(&self.tcx()),
             &format!(
@@ -276,6 +285,12 @@ impl NiceRegionError<'me, 'gcx, 'tcx> {
             .tcx()
             .any_free_region_meets(&actual_trait_ref.self_ty(), |r| Some(r) == vid);
 
+        debug!("try_report_placeholders_trait: actual_has_vid={:?}", actual_has_vid);
+        debug!("try_report_placeholders_trait: expected_has_vid={:?}", expected_has_vid);
+        debug!("try_report_placeholders_trait: has_sub={:?}", has_sub);
+        debug!("try_report_placeholders_trait: has_sup={:?}", has_sup);
+        debug!("try_report_placeholders_trait: self_ty_has_vid={:?}", self_ty_has_vid);
+
         RegionHighlightMode::maybe_highlighting_region(sub_placeholder, has_sub, || {
             RegionHighlightMode::maybe_highlighting_region(sup_placeholder, has_sup, || {
                 match (has_sub, has_sup) {