From 21dbf4949edd87c81f7eb8396fb4f91ef76a10a8 Mon Sep 17 00:00:00 2001 From: John Hodge Date: Sun, 28 Aug 2016 12:49:24 +0800 Subject: Expand - Support #[cfg] on use statements --- src/dump_as_rust.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/dump_as_rust.cpp') diff --git a/src/dump_as_rust.cpp b/src/dump_as_rust.cpp index 3c3a215d..8c79c744 100644 --- a/src/dump_as_rust.cpp +++ b/src/dump_as_rust.cpp @@ -561,6 +561,9 @@ void RustPrinter::handle_module(const AST::Module& mod) // m_os << "\n"; // need_nl = false; //} + if( i.data.path == AST::Path() ) { + continue ; + } m_os << indent() << (i.is_pub ? "pub " : "") << "use " << i.data; if( i.name == "" ) { -- cgit v1.2.3