-
-
Notifications
You must be signed in to change notification settings - Fork 14.4k
Allow invoking all help options at once #150767
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Collaborator
Member
|
could you add some tests for this, please? |
Contributor
Author
|
Added tests for the new combined help behavior, as well as testing the current behavior of |
Contributor
|
r? compiler |
jieyouxu
approved these changes
Jan 18, 2026
Member
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Member
|
@bors r+ |
Contributor
JonathanBrouwer
added a commit
to JonathanBrouwer/rust
that referenced
this pull request
Jan 18, 2026
Allow invoking all help options at once Implements rust-lang#150442 Help messages are printed in the order they are invoked, but only once (e.g. `--help -C help --help` prints regular help then codegen help). Lint groups (`-Whelp`) are always printed last due to necessarily coming later in the compiler pipeline. Adds `help` flags to `-C` and `-Z` to avoid an error in `build_session_options`. cc @bjorn3 [#t-compiler/major changes > Allow combining &rust-lang#96;--help -C help -Z help -… compiler-team#954 @ 💬](https://rust-lang.zulipchat.com/#narrow/channel/233931-t-compiler.2Fmajor-changes/topic/Allow.20combining.20.60--help.20-C.20help.20-Z.20help.20-.E2.80.A6.20compiler-team.23954/near/564358190) - this currently maintains the behaviour of unrecognized options always failing-fast, as this happens within `getopt`s parsing, before we can even check if help options are present.
This was referenced Jan 18, 2026
rust-bors bot
pushed a commit
that referenced
this pull request
Jan 18, 2026
…uwer Rollup of 7 pull requests Successful merges: - #150767 (Allow invoking all help options at once) - #150886 (Added mGCA related tests) - #151245 (Explicitly list crate level attrs) - #151268 (Fix ICE on inconsistent import resolution with macro-attributed extern crate) - #151275 (Normalize type_const items even with feature `generic_const_exprs`) - #151288 (Use `find_attr` instead of `attr::contains_name` in `lower_const_item_rhs`) - #151321 (Port #![no_main] to the attribute parser.) r? @ghost
rust-timer
added a commit
that referenced
this pull request
Jan 18, 2026
Rollup merge of #150767 - all-help, r=jieyouxu Allow invoking all help options at once Implements #150442 Help messages are printed in the order they are invoked, but only once (e.g. `--help -C help --help` prints regular help then codegen help). Lint groups (`-Whelp`) are always printed last due to necessarily coming later in the compiler pipeline. Adds `help` flags to `-C` and `-Z` to avoid an error in `build_session_options`. cc @bjorn3 [#t-compiler/major changes > Allow combining `--help -C help -Z help -… compiler-team#954 @ 💬](https://rust-lang.zulipchat.com/#narrow/channel/233931-t-compiler.2Fmajor-changes/topic/Allow.20combining.20.60--help.20-C.20help.20-Z.20help.20-.E2.80.A6.20compiler-team.23954/near/564358190) - this currently maintains the behaviour of unrecognized options always failing-fast, as this happens within `getopt`s parsing, before we can even check if help options are present.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
A-run-make
Area: port run-make Makefiles to rmake.rs
S-waiting-on-bors
Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Implements #150442
Help messages are printed in the order they are invoked, but only once (e.g.
--help -C help --helpprints regular help then codegen help).Lint groups (
-Whelp) are always printed last due to necessarily coming later in the compiler pipeline.Adds
helpflags to-Cand-Zto avoid an error inbuild_session_options.cc @bjorn3 #t-compiler/major changes > Allow combining `--help -C help -Z help -… compiler-team#954 @ 💬 - this currently maintains the behaviour of unrecognized options always failing-fast, as this happens within
getopts parsing, before we can even check if help options are present.