missing_public_function_example
/ missing_private_function_example
#12420
Labels
A-lint
Area: New lints
What it does
missing_public_function_example
would flag on functions that are:missing_private_function_example
would flag in the same cases except also for internal functions.Maybe there could be a config option to ignore
unstable
functions so this could be used instd
.Don't look for a
# Examples
header because a lot of times it isn't there or isn't needed.Advantage
This will help identify functions that have no example of usage, inspired by rust-lang/rust#121213.
Drawbacks
Possible FNs if this tries to detect the function in the example by name, but the example doesn't actually resolve to this function.
Example
Could be written as:
The text was updated successfully, but these errors were encountered: