Closed
Description
Using pub
qualifier with declarative macros 2.0 breaks the missing_docs
lint for private items, as well as exposes them with rustdoc.
The following code shouldn't produce warnings (playground):
//! ...
#![feature(decl_macro)]
#![warn(missing_docs)]
/// ...
pub mod foo {
// Try to comment out the macro, and warnings will be disappeared.
pub macro bar() { println!("bar"); }
#[allow(dead_code)]
fn baz() {}
}
fn main() {}
rustc --version --verbose
:
rustc 1.22.0-nightly (dcbbfb6e8 2017-10-12)
binary: rustc
commit-hash: dcbbfb6e807fdff9c9ba80073bb755f9d9d95e31
commit-date: 2017-10-12
host: x86_64-unknown-linux-gnu
release: 1.22.0-nightly
LLVM version: 4.0
Metadata
Metadata
Assignees
Labels
Area: Declarative macros 2.0 (#39412)Area: Lints (warnings about flaws in source code) such as unused_mut.Category: This is a bug.Call for participation: An issue has been fixed and does not reproduce, but no test has been added.Relevant to the compiler team, which will review and decide on the PR/issue.