@@ -1071,7 +1071,8 @@ impl<'a, 'b, 'tcx> BuildReducedGraphVisitor<'a, 'b, 'tcx> { |
|
|
1071 |
1071 |
let import = macro_use_import(self, span); |
1072 |
1072 |
self.r.potentially_unused_imports.push(import); |
1073 |
1073 |
module.for_each_child(self, |this, ident, ns, binding |
1074 |
|
-if ns == MacroNS { |
|
1074 |
+if ns == MacroNS && this.r.is_accessible_from(binding.vis, this.parent_scope.module) |
|
1075 |
+{ |
1075 |
1076 |
let imported_binding = this.r.import(binding, import); |
1076 |
1077 |
this.add_macro_use_binding(ident.name, imported_binding, span, allow_shadowing); |
1077 |
1078 |
} |