
Change the logic such that linking from a public to a private item always triggers intra_doc_link_resolution_failure. Previously, the warning was not emitted when --document-private-items is passed. Also don't rely anymore on the item's visibility, which would falsely trigger the lint now that the check for --document-private-items is gone.
9 lines
314 B
Rust
9 lines
314 B
Rust
// check-pass
|
|
// revisions: public private
|
|
// [private]compile-flags: --document-private-items
|
|
|
|
/// docs [DontDocMe]
|
|
//~^ WARNING public documentation for `DocMe` links to private item `DontDocMe`
|
|
// FIXME: for [private] we should also make sure the link was actually generated
|
|
pub struct DocMe;
|
|
struct DontDocMe;
|