-
Notifications
You must be signed in to change notification settings - Fork 13k
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
Always include a position span in rustc_parse_format::Argument
#99987
Conversation
Some changes occurred in src/tools/clippy cc @rust-lang/clippy |
r? @fee1-dead (rust-highfive has picked a reviewer for you, use r? to override) |
The job Click to see the possible cause of the failure (guessed by this bot)
|
Looks spurious, I hit re-run |
cc @PrestonFrom, you may or may not care about this but it's code you've recently touched |
Looks like a good change. Curious is adding the span to position instead of argument makes sense? |
I moved it up into |
That makes sense to me! |
@bors r+ |
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.
LGTM! Thanks
…n, r=fee1-dead Always include a position span in `rustc_parse_format::Argument` Moves the spans from the `Position` enum to always be included in the `Argument` struct. Doesn't make any changes to use it in rustc, but it will be useful for some upcoming Clippy lints
…iaskrgr Rollup of 7 pull requests Successful merges: - rust-lang#99987 (Always include a position span in `rustc_parse_format::Argument`) - rust-lang#100005 (Remove Clean trait for ast::Attribute and improve Attributes::from_ast) - rust-lang#100025 (Remove redundant `TransferWrapper` struct) - rust-lang#100045 (Properly reject the `may_unwind` option in `global_asm!`) - rust-lang#100052 (RISC-V ASM test: relax label name constraint.) - rust-lang#100053 (move [`assertions_on_result_states`] to restriction) - rust-lang#100057 (Remove more Clean trait implementations) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
…n, r=fee1-dead Always include a position span in `rustc_parse_format::Argument` Moves the spans from the `Position` enum to always be included in the `Argument` struct. Doesn't make any changes to use it in rustc, but it will be useful for some upcoming Clippy lints
…fee1-dead Fix rustc_parse_format precision & width spans When a `precision`/`width` was `CountIsName - {:name$}` or `CountIs - {:10}` the `precision_span`/`width_span` was set to `None` For `width` the name span in `CountIsName(_, name_span)` had its `.start` off by one r? `@fee1-dead` / cc `@PrestonFrom` since this is similar to rust-lang#99987
…fee1-dead Fix rustc_parse_format precision & width spans When a `precision`/`width` was `CountIsName - {:name$}` or `CountIs - {:10}` the `precision_span`/`width_span` was set to `None` For `width` the name span in `CountIsName(_, name_span)` had its `.start` off by one r? ``@fee1-dead`` / cc ``@PrestonFrom`` since this is similar to rust-lang#99987
Moves the spans from the
Position
enum to always be included in theArgument
struct. Doesn't make any changes to use it in rustc, but it will be useful for some upcoming Clippy lints