diff options
| author | Niko Matsakis <niko@alum.mit.edu> | 2018-10-02 14:05:39 -0400 |
|---|---|---|
| committer | Niko Matsakis <niko@alum.mit.edu> | 2018-10-08 19:21:22 -0400 |
| commit | ccba716099c61816734f8daa7459001f6fdea0af (patch) | |
| tree | 7dfb744c6deac72afdecd07431a0fca73e847b43 | |
| parent | 16e1aaf09da5d516487118e048bf37e8c44f1b77 (diff) | |
| download | rust-ccba716099c61816734f8daa7459001f6fdea0af.tar.gz rust-ccba716099c61816734f8daa7459001f6fdea0af.zip | |
add some `debug!` to type checking
| -rw-r--r-- | src/librustc_typeck/check/mod.rs | 23 |
1 files changed, 19 insertions, 4 deletions
diff --git a/src/librustc_typeck/check/mod.rs b/src/librustc_typeck/check/mod.rs index 52ed279b853..be8b16dd2f5 100644 --- a/src/librustc_typeck/check/mod.rs +++ b/src/librustc_typeck/check/mod.rs @@ -3759,6 +3759,13 @@ impl<'a, 'gcx, 'tcx> FnCtxt<'a, 'gcx, 'tcx> { expected: Expectation<'tcx>, needs: Needs ) -> Ty<'tcx> { + debug!( + "check_expr_kind(expr={:?}, expected={:?}, needs={:?})", + expr, + expected, + needs, + ); + let tcx = self.tcx; let id = expr.id; match expr.node { @@ -4988,10 +4995,13 @@ impl<'a, 'gcx, 'tcx> FnCtxt<'a, 'gcx, 'tcx> { span: Span, node_id: ast::NodeId) -> (Ty<'tcx>, Def) { - debug!("instantiate_value_path(path={:?}, def={:?}, node_id={})", - segments, - def, - node_id); + debug!( + "instantiate_value_path(segments={:?}, self_ty={:?}, def={:?}, node_id={})", + segments, + self_ty, + def, + node_id, + ); let path_segs = self.def_ids_for_path_segments(segments, def); @@ -5201,6 +5211,11 @@ impl<'a, 'gcx, 'tcx> FnCtxt<'a, 'gcx, 'tcx> { let hir_id = self.tcx.hir.node_to_hir_id(node_id); self.write_substs(hir_id, substs); + debug!( + "instantiate_value_path: id={:?} substs={:?}", + node_id, + substs, + ); self.write_user_substs_from_substs(hir_id, substs); (ty_substituted, new_def) |
