Skip to content

Fix overlong impl #1091

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 4 commits into from
Jul 26, 2016
Merged

Fix overlong impl #1091

merged 4 commits into from
Jul 26, 2016

Conversation

fabric-and-ink
Copy link
Contributor

Fix #1048.

Will also look into splitting the impl at the 'for'.

@@ -470,7 +471,7 @@ pub fn format_impl(context: &RewriteContext, item: &ast::Item, offset: Indent) -
result.push_str(" for ");
}

let budget = try_opt!(context.config.max_width.checked_sub(result.len()));
let budget = try_opt!(context.config.max_width.checked_sub(result.len() + 1));
Copy link
Member

Choose a reason for hiding this comment

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

Could you add a comment for why we need the + 1 please?

@nrc
Copy link
Member

nrc commented Jul 10, 2016

Looks good, just a couple of minor comments, then r+

@fabric-and-ink
Copy link
Contributor Author

@nrc I think one of the checks timed out. Could you please restart them?

@nrc nrc merged commit e76cb6a into rust-lang:master Jul 26, 2016
@nrc
Copy link
Member

nrc commented Jul 26, 2016

Thank you for the PR!

@fabric-and-ink
Copy link
Contributor Author

My pleasure!

@fabric-and-ink fabric-and-ink deleted the i-1048 branch July 26, 2016 05:43
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