From e76dddd61078e1636ad8dc2ed02d53d37ae987e1 Mon Sep 17 00:00:00 2001 From: Edwin Cheng Date: Wed, 4 Mar 2020 20:37:16 +0800 Subject: Add more log --- crates/ra_hir_expand/src/db.rs | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'crates/ra_hir_expand') diff --git a/crates/ra_hir_expand/src/db.rs b/crates/ra_hir_expand/src/db.rs index 32e0d5ced..d29985d0b 100644 --- a/crates/ra_hir_expand/src/db.rs +++ b/crates/ra_hir_expand/src/db.rs @@ -181,6 +181,15 @@ pub(crate) fn parse_macro( err, node.value ); + + let mut parent = loc.kind.file_id().call_node(db); + while let Some(node) = parent.clone() { + log::warn!( + "parent: macro_call: {:#})", + node.value + ); + parent = node.file_id.call_node(db); + } } _ => { log::warn!("fail on macro_parse: (reason: {})", err); -- cgit v1.2.3