-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Allow cargo fix
to partially apply mismatched_lifetime_syntaxes
#144601
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
bors
merged 1 commit into
rust-lang:master
from
kornelski:cargo-fix-mismatched_lifetime_syntaxes
Aug 7, 2025
Merged
Allow cargo fix
to partially apply mismatched_lifetime_syntaxes
#144601
bors
merged 1 commit into
rust-lang:master
from
kornelski:cargo-fix-mismatched_lifetime_syntaxes
Aug 7, 2025
+45
−24
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
rustbot has assigned @petrochenkov. Use |
petrochenkov
approved these changes
Jul 29, 2025
Looks reasonable to me. |
I think it should work. @bors r=petrochenkov |
@bors rollup |
tgross35
added a commit
to tgross35/rust
that referenced
this pull request
Aug 7, 2025
…etime_syntaxes, r=petrochenkov Allow `cargo fix` to partially apply `mismatched_lifetime_syntaxes` Workaround for rust-lang#144588 (comment) Not all suggestions have to be hidden from `cargo fix`, only redundant ones. The redundant ones are already hidden from the user, so the same `tool_only` flag can be used to hide them from `cargo fix`. This way `cargo fix` will be able to correctly apply the fixes, and will apply only the fix that the compiler visibly suggests to the user.
bors
added a commit
that referenced
this pull request
Aug 7, 2025
Rollup of 7 pull requests Successful merges: - #138689 (add nvptx_target_feature) - #140267 (implement continue_ok and break_ok for ControlFlow) - #143807 (Pass -Werror when building the LLVM wrapper) - #144369 (Upgrade semicolon_in_expressions_from_macros from warn to deny) - #144601 (Allow `cargo fix` to partially apply `mismatched_lifetime_syntaxes`) - #144682 (Stabilize `strict_overflow_ops`) - #145026 (Update books) r? `@ghost` `@rustbot` modify labels: rollup
bors
added a commit
that referenced
this pull request
Aug 7, 2025
Rollup of 19 pull requests Successful merges: - #137831 (Tweak auto trait errors) - #138689 (add nvptx_target_feature) - #140267 (implement continue_ok and break_ok for ControlFlow) - #143028 (emit `StorageLive` and schedule `StorageDead` for `let`-`else`'s bindings after matching) - #143764 (lower pattern bindings in the order they're written and base drop order on primary bindings' order) - #143808 (Port `#[should_panic]` to the new attribute parsing infrastructure ) - #143906 (Miri: non-deterministic floating point operations in `foreign_items`) - #143929 (Mark all deprecation lints in name resolution as deny-by-default and report-in-deps) - #144133 (Stabilize const TypeId::of) - #144369 (Upgrade semicolon_in_expressions_from_macros from warn to deny) - #144439 (Introduce ModernIdent type to unify macro 2.0 hygiene handling) - #144473 (Address libunwind.a inconsistency issues in the bootstrap program) - #144601 (Allow `cargo fix` to partially apply `mismatched_lifetime_syntaxes`) - #144650 (Additional tce tests) - #144659 (bootstrap: refactor mingw dist and fix gnullvm) - #144682 (Stabilize `strict_overflow_ops`) - #145026 (Update books) - #145033 (Reimplement `print_region` in `type_name.rs`.) - #145040 (rustc-dev-guide subtree update) Failed merges: - #143857 (Port #[macro_export] to the new attribute parsing infrastructure) r? `@ghost` `@rustbot` modify labels: rollup
rust-timer
added a commit
that referenced
this pull request
Aug 7, 2025
Rollup merge of #144601 - kornelski:cargo-fix-mismatched_lifetime_syntaxes, r=petrochenkov Allow `cargo fix` to partially apply `mismatched_lifetime_syntaxes` Workaround for #144588 (comment) Not all suggestions have to be hidden from `cargo fix`, only redundant ones. The redundant ones are already hidden from the user, so the same `tool_only` flag can be used to hide them from `cargo fix`. This way `cargo fix` will be able to correctly apply the fixes, and will apply only the fix that the compiler visibly suggests to the user.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
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.
Workaround for #144588 (comment)
Not all suggestions have to be hidden from
cargo fix
, only redundant ones. The redundant ones are already hidden from the user, so the sametool_only
flag can be used to hide them fromcargo fix
. This waycargo fix
will be able to correctly apply the fixes, and will apply only the fix that the compiler visibly suggests to the user.