提交 8fbcb9c5 编写于 作者: D dylan_DPC

add warning for missing docs

上级 a6201f9a
......@@ -12,7 +12,7 @@
// compile-pass
#![warn(unused_imports)]
#![warn(missing_docs)] //~ WARN: missing documentation for crate [missing_docs]
#![warn(missing_docs)]
#[macro_use]
extern crate lints_in_foreign_macros;
......@@ -25,5 +25,6 @@
mod b { bar!(); }
mod c { baz!(use std::string::ToString;); } //~ WARN: unused import
mod d { baz2!(use std::string::ToString;); } //~ WARN: unused import
mod e { baz!(pub fn undocumented() {}); }//~ WARN: missing documentation for a function
fn main() {}
......@@ -29,17 +29,17 @@ warning: missing documentation for crate
--> $DIR/lints-in-foreign-macros.rs:14:1
|
LL | / #![warn(unused_imports)]
LL | | #![warn(missing_docs)] //~ WARN: missing documentation for crate [missing_docs]
LL | | #![warn(missing_docs)]
LL | |
LL | | #[macro_use]
... |
LL | |
LL | | fn main() {}
LL | | fn main() {} //~ WARN: missing documentation for crate [missing_docs]
| |____________^
|
note: lint level defined here
--> $DIR/lints-in-foreign-macros.rs:15:9
|
LL | #![warn(missing_docs)] //~ WARN: missing documentation for crate [missing_docs]
LL | #![warn(missing_docs)]
| ^^^^^^^^^^^^
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册