-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
Make rustdoc --passes
and rustdoc --no-defaults
have no effect
#91714
Comments
@rfcbot fcp merge |
Team member @jyn514 has proposed to merge this. The next step is review by the rest of the tagged team members: No concerns currently listed. Once a majority of reviewers approve (and at most 2 approvals are outstanding), this will enter its final comment period. If you spot a major issue that hasn't been raised at any point in this process, please speak up! See this document for info about what commands tagged team members can give me. |
Oh, I forgot to mention earlier - there's precedent for doing this for other deprecated flags:
|
@rfcbot reviewed +1. I've been wanting to get rid of these flags for a while. Should we use a future-incompatibility warning so that it'd be more feasible to potentially remove the flags in the future?
Why everything except |
I don't have any objection to doing that, but I don't think it's a big deal either way - the main advantage of future-incompat warnings is they're shown for dependencies, but there's no way to pass flags to a dependency without also passing them to the main crate. |
I meant more that it would signal that you really shouldn't be using these flags and thus make it easier to potentially remove in the future. |
🔔 This is now entering its final comment period, as per the review above. 🔔 |
Mentoring instructions: remove Lines 130 to 138 in 8f117a7
Also remove DefaultPassOption::None : Line 609 in 8f117a7
|
@rustbot claim |
cc #82824 |
The final comment period, with a disposition to merge, as per the review above, is now complete. As the automated representative of the governance process, I would like to thank the author for their work and everyone else who contributed. This will be merged soon. |
Currently,
rustdoc --passes
does one of two things:--passes list
shows a list of available passes:rustdoc --passes collect-trait-impls
will add that specific pass to the list of passes rustdoc executes (I think this is intended to be used with--no-defaults
, which is also deprecated).Both of these are stable, so unfortunately we can't remove them; 2. is deprecated and 1. should be soon (after #91713 is fixed). However, this is not a very useful sort of stability, because the names and number of passes is not stable, and rustdoc is very likely to be buggy if you don't run all passes (there's no sort of test for this).
I propose not just deprecating
--passes
and--no-defaults
but making them a no-op altogether, which means less complexity both for users and in the rustdoc codebase. I also suggest removing the CLI help at the same time (and just say "this flag is a no-op").Note that the only other deprecated flag,
--input-format
, is also currently a no-op when used with--input-format rust
, and a hard error otherwise. We could go further and make everything but--passes=list
be a hard error, but that seems like more of a breaking change than necessary for the goal of reducing complexity.The text was updated successfully, but these errors were encountered: