Skip to content

Add commas after skipped arms when needed #749

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

Merged
merged 1 commit into from
Jan 8, 2016

Conversation

sanxiyn
Copy link
Member

@sanxiyn sanxiyn commented Jan 8, 2016

Fix #737.

fn match_skip() {
let _ = match Some(1) {
#[rustfmt_skip]
Some(n) => n,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you change both patterns to something non-canonical to check that rustfmt does not change the Some line, but does reformat the None line?

@marcusklaas
Copy link
Contributor

Looks good to me. r+ with updated test.

@sanxiyn
Copy link
Member Author

sanxiyn commented Jan 8, 2016

Test updated.

marcusklaas added a commit that referenced this pull request Jan 8, 2016
Add commas after skipped arms when needed
@marcusklaas marcusklaas merged commit 66abad9 into rust-lang:master Jan 8, 2016
@marcusklaas
Copy link
Contributor

Thanks!

@sanxiyn sanxiyn deleted the skip-arm branch January 8, 2016 13:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants