Add test for reexported items lints

This commit is contained in:
Guillaume Gomez 2020-09-27 21:22:39 +02:00
parent 130fd1a970
commit 7c0d576c59
2 changed files with 31 additions and 0 deletions

View File

@ -0,0 +1,8 @@
#![deny(broken_intra_doc_links)]
/// [somewhere]
//~^ ERROR unresolved link to `somewhere`
pub use std::str::*;
/// [aloha]
//~^ ERROR unresolved link to `aloha`
pub use std::task::RawWakerVTable;

View File

@ -0,0 +1,23 @@
error: unresolved link to `somewhere`
--> $DIR/pub-export-lint.rs:3:6
|
LL | /// [somewhere]
| ^^^^^^^^^ the module `pub_export_lint` contains no item named `somewhere`
|
note: the lint level is defined here
--> $DIR/pub-export-lint.rs:1:9
|
LL | #![deny(broken_intra_doc_links)]
| ^^^^^^^^^^^^^^^^^^^^^^
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: unresolved link to `aloha`
--> $DIR/pub-export-lint.rs:6:6
|
LL | /// [aloha]
| ^^^^^ the module `pub_export_lint` contains no item named `aloha`
|
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: aborting due to 2 previous errors