-
Notifications
You must be signed in to change notification settings - Fork 1.8k
fix(manual_assert): use multipart suggestion instead of simple span_suggestion #15226
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
base: master
Are you sure you want to change the base?
fix(manual_assert): use multipart suggestion instead of simple span_suggestion #15226
Conversation
…suggestion This resolves rust-lang#13099 by converting the suggestion into a multipart suggestion, allowing rustfix to apply it correctly.
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.
It removes the @no-rustfix annotation in the corresponding UI test
I don't see the removal of @no-rustfix
in the changes
LL + multiline | ||
LL + comment */ | ||
LL + /// Doc comment | ||
LL + // comment after `panic!` |
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.
shouldn't this comment have stayed after panic!
, now assert!
?
☔ The latest upstream changes (possibly #14896) made this pull request unmergeable. Please resolve the merge conflicts. |
This PR updates the
manual_assert
lint to usemultipart_suggestion
instead of a singlespan_suggestion
.This change allows Clippy to properly apply suggestions when comments are present before or around the
if
-then-panic!
block. It removes the@no-rustfix
annotation in the corresponding UI test and updates the.stderr
file accordingly.Fixes: #13099
changelog: fix manual_assert lint suggestion format