about summary refs log tree commit diff
path: root/src/librustc_save_analysis
diff options
context:
space:
mode:
authorMazdak Farrokhzad <twingoow@gmail.com>2020-03-15 15:40:08 +0100
committerGitHub <noreply@github.com>2020-03-15 15:40:08 +0100
commit8bca839fdfd654581468019a3a69cc6987b585ea (patch)
treecdfab004c4510442959db15c22d78fbf0e84298c /src/librustc_save_analysis
parentcc1623267b344684c165a0a6972f2791e2a46728 (diff)
parent01a0c6d441a8630fe179420525e42920ab69d976 (diff)
downloadrust-8bca839fdfd654581468019a3a69cc6987b585ea.tar.gz
rust-8bca839fdfd654581468019a3a69cc6987b585ea.zip
Rollup merge of #69988 - petrochenkov:nomacrodef, r=Centril
rustc_metadata: Remove `rmeta::MacroDef`

And other related cleanups.

Follow-up to https://github.com/rust-lang/rust/pull/66364.
r? @Centril
Diffstat (limited to 'src/librustc_save_analysis')
-rw-r--r--src/librustc_save_analysis/lib.rs13
1 files changed, 0 insertions, 13 deletions
diff --git a/src/librustc_save_analysis/lib.rs b/src/librustc_save_analysis/lib.rs
index e2fe6fe82a7..8b0120c34e0 100644
--- a/src/librustc_save_analysis/lib.rs
+++ b/src/librustc_save_analysis/lib.rs
@@ -794,19 +794,6 @@ impl<'l, 'tcx> SaveContext<'l, 'tcx> {
             ExpnKind::Root | ExpnKind::AstPass(_) | ExpnKind::Desugaring(_) => return None,
         };
 
-        // If the callee is an imported macro from an external crate, need to get
-        // the source span and name from the session, as their spans are localized
-        // when read in, and no longer correspond to the source.
-        if let Some(mac) = self.tcx.sess.imported_macro_spans.borrow().get(&callee.def_site) {
-            let &(ref mac_name, mac_span) = mac;
-            let mac_span = self.span_from_span(mac_span);
-            return Some(MacroRef {
-                span: callsite_span,
-                qualname: mac_name.clone(), // FIXME: generate the real qualname
-                callee_span: mac_span,
-            });
-        }
-
         let callee_span = self.span_from_span(callee.def_site);
         Some(MacroRef {
             span: callsite_span,