add a lint for pub
items that are not reachable from crate root
#45521
Labels
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
As part of #44660, we need to create a lint for items that are declared as
pub
but are not reachable from the crate root (such items are advised to usecrate
visibility instead).The lint should probably be allow-by-default for now, to start.
This issue needs precise mentoring instructions. There are some tips regarding adding "future compatibility" lints here in this forge article -- see the section "Issuing future compatibility warnings". We don't need a future compatibility lint here, so we can skip the stuff specific to that, but it does give some more general advice on how to make lints overall.
The text was updated successfully, but these errors were encountered: