style: reformat comments for the current nightly rustfmt - #584
Merged
Conversation
The check-format CI job runs `cargo fmt --all -- --check` on an unpinned nightly toolchain, and .rustfmt.toml enables the unstable `wrap_comments` option — whose line-wrapping algorithm changed in a recent nightly. Files formatted under the older nightly no longer pass the check. Reflow the affected comments with the current nightly (rustfmt 1.10.0-nightly, 2026-08-30). Comment/whitespace only — no code changes. `cargo fmt --all -- --check` now passes clean.
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
问题
main 的
check-formatCI 失败(#582 合并后触发的那次跑):根因
check-formatjob 用 未固定版本的 nightly(toolchain: nightly)跑cargo fmt --all -- --check;.rustfmt.toml开了 unstable 的wrap_comments = true,其注释折行算法在近期 nightly 里变了;--check。跟 #582 无关(#582 只改了一个
.java文件,cargo fmt 不处理 Java)—— 只是 #582 那次 push 触发了用新 nightly 的检查。修复
用当前 nightly(rustfmt 1.10.0-nightly, 2026-08-30)重排受影响文件的注释。纯注释/空白,无任何代码逻辑改动(已核对:非注释改动行为空)。
验证
本地
cargo +nightly fmt --all -- --check→ exit 0、无 diff。🤖 Generated with Claude Code