Skip to content
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

rustc update: Remove variant visibility #332

Merged
merged 1 commit into from
Sep 19, 2015

Conversation

Kha
Copy link
Contributor

@Kha Kha commented Sep 19, 2015

@@ -531,8 +529,7 @@ impl<'a> FmtVisitor<'a> {

result.push('(');

let indent = self.block_indent + vis.len() + field.node.name.to_string().len() +
1; // Open paren
let indent = self.block_indent + field.node.name.to_string().len() + "(".len();
Copy link
Contributor Author

Choose a reason for hiding this comment

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

rustfmt didn't like the statement with or without line break, so I got a bit creative. It yields the same code under -O.

marcusklaas added a commit that referenced this pull request Sep 19, 2015
rustc update: Remove variant visibility
@marcusklaas marcusklaas merged commit 4e1fff8 into rust-lang:master Sep 19, 2015
@marcusklaas
Copy link
Contributor

Thanks!

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