-
-
Notifications
You must be signed in to change notification settings - Fork 14.5k
style: remove unneeded trailing commas #152372
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
Conversation
Make format-like macro calls look similar to what `cargo fmt` does automatically - remove trailing commas. When removing a comma, I also inlined some variables for consistency and clarity.
|
r? @mati865 rustbot has assigned @mati865. Use Why was this reviewer chosen?The reviewer was selected based on:
|
|
Should commas in the same module be removed in places like this? 🤔 |
|
@xizheyin that's a good question. The lint i wrote wouldn't catch these unless they have In this specific case, I think it is a good idea to remove that comma as it doesn't seem to have any impact. If it does, and both variants compile and pass tests, it would be a more significant problem - i.e. a comma becoming an important parameter to a "function-like" macro call is just wrong. |
|
@bors r+ rollup |
…n, r=mati865 style: remove unneeded trailing commas Make format-like macro calls look similar to what `cargo fmt` does automatically - remove trailing commas. When removing a comma, I also inlined some variables for consistency and clarity. I'm working on a [clippy lint](rust-lang/rust-clippy#16530) to make this process automatic.
…n, r=mati865 style: remove unneeded trailing commas Make format-like macro calls look similar to what `cargo fmt` does automatically - remove trailing commas. When removing a comma, I also inlined some variables for consistency and clarity. I'm working on a [clippy lint](rust-lang/rust-clippy#16530) to make this process automatic.
…uwer Rollup of 13 pull requests Successful merges: - #149937 (try enabling `linker-messages` by default again) - #151733 (Use function shims to make sure EII works on apple targets) - #152120 (Don't ICE on layout error in vtable computation) - #152419 (Move more query system code) - #152431 (Restrict the set of things that const stability can be applied to) - #152436 (Reenable a GCI+mGCA+GCPT test case) - #151142 (Support ADT types in type info reflection) - #152021 (Bump tvOS, visionOS and watchOS Aarch64 targets to tier 2) - #152146 (mGCA: Add associated const type check) - #152372 (style: remove unneeded trailing commas) - #152383 (BikeshedGuaranteedNoDrop trait: add comments indicating that it can be observed on stable) - #152397 (Update books) - #152441 (Fix typos and grammar in top-level and src/doc documentation)
…n, r=mati865 style: remove unneeded trailing commas Make format-like macro calls look similar to what `cargo fmt` does automatically - remove trailing commas. When removing a comma, I also inlined some variables for consistency and clarity. I'm working on a [clippy lint](rust-lang/rust-clippy#16530) to make this process automatic.
…n, r=mati865 style: remove unneeded trailing commas Make format-like macro calls look similar to what `cargo fmt` does automatically - remove trailing commas. When removing a comma, I also inlined some variables for consistency and clarity. I'm working on a [clippy lint](rust-lang/rust-clippy#16530) to make this process automatic.
…n, r=mati865 style: remove unneeded trailing commas Make format-like macro calls look similar to what `cargo fmt` does automatically - remove trailing commas. When removing a comma, I also inlined some variables for consistency and clarity. I'm working on a [clippy lint](rust-lang/rust-clippy#16530) to make this process automatic.
Rollup of 10 pull requests Successful merges: - #152120 (Don't ICE on layout error in vtable computation) - #152419 (Move more query system code) - #152431 (Restrict the set of things that const stability can be applied to) - #152436 (Reenable a GCI+mGCA+GCPT test case) - #152021 (Bump tvOS, visionOS and watchOS Aarch64 targets to tier 2) - #152146 (mGCA: Add associated const type check) - #152372 (style: remove unneeded trailing commas) - #152383 (BikeshedGuaranteedNoDrop trait: add comments indicating that it can be observed on stable) - #152397 (Update books) - #152441 (Fix typos and grammar in top-level and src/doc documentation)
…n, r=mati865 style: remove unneeded trailing commas Make format-like macro calls look similar to what `cargo fmt` does automatically - remove trailing commas. When removing a comma, I also inlined some variables for consistency and clarity. I'm working on a [clippy lint](rust-lang/rust-clippy#16530) to make this process automatic.
Rollup of 9 pull requests Successful merges: - #152419 (Move more query system code) - #152431 (Restrict the set of things that const stability can be applied to) - #152436 (Reenable a GCI+mGCA+GCPT test case) - #152021 (Bump tvOS, visionOS and watchOS Aarch64 targets to tier 2) - #152146 (mGCA: Add associated const type check) - #152372 (style: remove unneeded trailing commas) - #152383 (BikeshedGuaranteedNoDrop trait: add comments indicating that it can be observed on stable) - #152397 (Update books) - #152441 (Fix typos and grammar in top-level and src/doc documentation)
Rollup merge of #152372 - nyurik:clippy-rustc_trait_selection, r=mati865 style: remove unneeded trailing commas Make format-like macro calls look similar to what `cargo fmt` does automatically - remove trailing commas. When removing a comma, I also inlined some variables for consistency and clarity. I'm working on a [clippy lint](rust-lang/rust-clippy#16530) to make this process automatic.
Make format-like macro calls look similar to what
cargo fmtdoes automatically - remove trailing commas. When removing a comma, I also inlined some variables for consistency and clarity.I'm working on a clippy lint to make this process automatic.