Skip to content

[beta] Revert "Fixes adjustment of max_width within macros" (rust-lang/rustfmt#6651) and follow-up (rust-lang/rustfmt#7152) - #165380

Closed
jieyouxu wants to merge 2 commits into
rust-lang:betafrom
jieyouxu:jieyouxu/revert-macro-fmt
Closed

jieyouxu wants to merge 2 commits into
rust-lang:betafrom
jieyouxu:jieyouxu/revert-macro-fmt

Conversation

@jieyouxu

@jieyouxu jieyouxu commented Nov 3, 2026 •

Copy link
Copy Markdown
Member

View all comments

rust-lang/rust side beta-backport of rust-lang/rustfmt#7222.

Part of rust-lang/rustfmt#7223.
Closes rust-lang/rustfmt#7223.

See rust-lang/rustfmt#7221 (comment). This PR reverts both:

  1. Fixes adjustment of max_width within macros rustfmt#6651 (partially; I kept the baseline test commit but not the actual formatting change commit), and
  2. Use saturating arithmetics for adjust_max_width rustfmt#7152 (follow-up fix)

r? @ytmimi

Reverts rust-lang/rustfmt#7152.

This reverts commit 677b954590cc0d5e86cb97e7db4e4b5fb6290add, reversing
changes made to b4260f44f5d8cd538718b9046eb51baaa1eb8f5e.
Reverts rust-lang/rustfmt#6651 since it affects stable macro formatting,
even though `format_macro_bodies` is unstable option (unstability
applies only to the config, the "format macro bodies" value is stable
default formatting). We generally cannot make this change on SE 2024.

This reverts commit 93e78f2.
@rustbot

rustbot commented Nov 3, 2026

Copy link
Copy Markdown
Collaborator

rustfmt is developed in its own repository. If possible, consider making this change to rust-lang/rustfmt instead.

cc @rust-lang/rustfmt

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-rustfmt Relevant to the rustfmt team, which will review and decide on the PR/issue. labels Nov 3, 2026
@rustbot

rustbot commented Nov 3, 2026

Copy link
Copy Markdown
Collaborator

⚠️ Warning ⚠️

  • There are issue links (such as #123) in the commit messages of the following commits.
    Please move them to the PR description, to avoid spamming the issues with references to the commit, and so this bot can automatically canonicalize them to avoid issues with subtrees.

@jieyouxu jieyouxu added the beta-nominated Nominated for backporting to the compiler in the beta channel. label Nov 3, 2026
@jieyouxu

jieyouxu commented Nov 3, 2026

Copy link
Copy Markdown
Member Author

Marking as beta-accepted as discussed in rust-lang/rustfmt#7221 (comment) to prevent formatting changes to stable option ungated by style edition from reaching stable.
@rustbot label: +beta-accepted

@rustbot rustbot added the beta-accepted Accepted for backporting to the compiler in the beta channel. label Nov 3, 2026
@ytmimi

ytmimi commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

@bors r+ rollup=never

@rust-bors

rust-bors Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

📌 Commit 07f4abe has been tentatively approved by ytmimi

It will be put into the queue for this repository once PR CI succeeds.

@rust-bors rust-bors Bot added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Nov 3, 2026
@ytmimi

ytmimi commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

@jieyouxu should we bump the priority on this one?

@jieyouxu jieyouxu mentioned this pull request Nov 3, 2026
@jieyouxu

jieyouxu commented Nov 3, 2026

Copy link
Copy Markdown
Member Author

@jieyouxu should we bump the priority on this one?

@ytmimi I'm asking in #165368 (comment) which is the current beta backport rollup batch test. That backport batch's illumos job isn't looking very good (i.e. on track to time out), so we might be able to roll it into that batch. Otherwise, we will bump this PR to p=5.

@jieyouxu

This comment was marked as off-topic.

@rust-bors

This comment was marked as off-topic.

@jieyouxu

jieyouxu commented Nov 3, 2026

Copy link
Copy Markdown
Member Author

@bors r=ytmimi force

@rust-bors

rust-bors Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

📌 Commit 07f4abe has been approved by ytmimi

It is now in the queue for this repository.

@jieyouxu

jieyouxu commented Nov 3, 2026

Copy link
Copy Markdown
Member Author

@bors p=5 (in case not included in backport rollup)

@jieyouxu

jieyouxu commented Nov 3, 2026

Copy link
Copy Markdown
Member Author

@bors p=6 (to be ahead of rollups)

@rust-bors

rust-bors Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

⌛ Testing commit 07f4abe with merge 5b50a93...

Workflow: https://github.com/rust-lang/rust/actions/runs/41570191142

rust-bors Bot pushed a commit that referenced this pull request Nov 3, 2026
[beta] Revert "Fixes adjustment of `max_width` within macros" (rust-lang/rustfmt#6651) and follow-up (rust-lang/rustfmt#7152)

rust-lang/rust side beta-backport of rust-lang/rustfmt#7222.

Part of rust-lang/rustfmt#7223.
Closes rust-lang/rustfmt#7223.

See rust-lang/rustfmt#7221 (comment). This PR reverts both:

1. rust-lang/rustfmt#6651 (partially; I kept the baseline test commit but not the actual formatting change commit), and
2. rust-lang/rustfmt#7152 (follow-up fix)

r? @ytmimi
@jieyouxu

jieyouxu commented Nov 3, 2026

Copy link
Copy Markdown
Member Author

Yielding to beta backport rollup
@bors yield

@rust-bors

rust-bors Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

Auto build was cancelled. Cancelled workflows:

The next pull request likely to be tested is #165380.

@rust-bors

rust-bors Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

⌛ Testing commit 07f4abe with merge cc63231...

Workflow: https://github.com/rust-lang/rust/actions/runs/41572355466

rust-bors Bot pushed a commit that referenced this pull request Nov 3, 2026
[beta] Revert "Fixes adjustment of `max_width` within macros" (rust-lang/rustfmt#6651) and follow-up (rust-lang/rustfmt#7152)

rust-lang/rust side beta-backport of rust-lang/rustfmt#7222.

Part of rust-lang/rustfmt#7223.
Closes rust-lang/rustfmt#7223.

See rust-lang/rustfmt#7221 (comment). This PR reverts both:

1. rust-lang/rustfmt#6651 (partially; I kept the baseline test commit but not the actual formatting change commit), and
2. rust-lang/rustfmt#7152 (follow-up fix)

r? @ytmimi
@jieyouxu

jieyouxu commented Nov 3, 2026

Copy link
Copy Markdown
Member Author

@bors yield

@rust-bors

rust-bors Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

Auto build was cancelled. Cancelled workflows:

The next pull request likely to be tested is #165368.

rust-bors Bot pushed a commit that referenced this pull request Nov 3, 2026
[beta] backports

- [beta] Revert "riscv: stabilize 'd' and 'f' target features" #165333
- [rustdoc] Move the creation of `IndividualTestOptions` into the test runner closure to ensure the temporary folder is removed right after the test is done running #164202
- rustdoc: don't panic on a nested use group with no path prefix #164883
- Gate `z` inline asm template modifier #165083
- Fix ICE in prelude edition lint #165129
- Update LLVM submodule #165133
- [beta] Revert "Fixes adjustment of `max_width` within macros" (rust-lang/rustfmt#6651) and follow-up (rust-lang/rustfmt#7152) #165380

r? me
@rust-bors

rust-bors Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

⌛ Testing commit 07f4abe with merge f29b4d7...

Workflow: https://github.com/rust-lang/rust/actions/runs/41590858659

rust-bors Bot pushed a commit that referenced this pull request Nov 3, 2026
[beta] Revert "Fixes adjustment of `max_width` within macros" (rust-lang/rustfmt#6651) and follow-up (rust-lang/rustfmt#7152)

rust-lang/rust side beta-backport of rust-lang/rustfmt#7222.

Part of rust-lang/rustfmt#7223.
Closes rust-lang/rustfmt#7223.

See rust-lang/rustfmt#7221 (comment). This PR reverts both:

1. rust-lang/rustfmt#6651 (partially; I kept the baseline test commit but not the actual formatting change commit), and
2. rust-lang/rustfmt#7152 (follow-up fix)

r? @ytmimi
@jieyouxu

jieyouxu commented Nov 3, 2026

Copy link
Copy Markdown
Member Author

@bors r-

@rust-bors rust-bors Bot added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Nov 3, 2026
@rust-bors

rust-bors Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

This pull request was unapproved.

Auto build was cancelled due to unapproval. Cancelled workflows:

View changes since this unapproval

@jieyouxu

jieyouxu commented Nov 3, 2026

Copy link
Copy Markdown
Member Author

Commits merged in #165368.

@jieyouxu jieyouxu closed this Nov 3, 2026
@rustbot rustbot removed the S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. label Nov 3, 2026
@jieyouxu
jieyouxu deleted the jieyouxu/revert-macro-fmt branch November 3, 2026 06:57
@jieyouxu jieyouxu removed the beta-nominated Nominated for backporting to the compiler in the beta channel. label Nov 3, 2026
@jieyouxu jieyouxu added this to the 1.100.0 milestone Nov 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

beta-accepted Accepted for backporting to the compiler in the beta channel. T-rustfmt Relevant to the rustfmt team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants