-
Notifications
You must be signed in to change notification settings - Fork 1.7k
missing_safety_doc warning even on functions internal to crate #4608
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Oops. On one hand, the last thing I want is people to learn to delete their docs to silence the lint. On the other hand, where are you going to document the preconditions if not on the module boundary. I guess the best solution is to split the lint by actual visibility and make the |
I agree that the lint should be split by visibility, not by existing docs. I mentioned the |
account for doc visibility This fixes #4608. Also I noticed that the lint failed to look at trait and impl items. There's a small bit of fallout in the code, too, but not enough to warrant its own commit. changelog: check docs of trait items and impl items, also make `missing_safety_doc` account for visibility
Was |
Functions which are public in their module, but inside a private module, are not exposed in the API docs. In fact they do not get a warning with
warn(missing_docs)
. They still get a warning withwarn(clippy::missing_safety_doc)
.The text was updated successfully, but these errors were encountered: