Merge pull request #3141 from dfyz/issue-2810

Try to fix formatting failures on Windows (issue #2810)
This commit is contained in:
Nick Cameron 2018-10-29 11:29:51 +13:00 committed by GitHub
commit 1f64f4012f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 15 additions and 1 deletions

View File

@ -1347,7 +1347,7 @@ impl MacroBranch {
.fold( .fold(
(String::new(), true), (String::new(), true),
|(mut s, need_indent), (i, (kind, ref l))| { |(mut s, need_indent), (i, (kind, ref l))| {
if !l.is_empty() if !is_empty_line(l)
&& need_indent && need_indent
&& !new_body_snippet.is_line_non_formatted(i + 1) && !new_body_snippet.is_line_non_formatted(i + 1)
{ {

View File

@ -0,0 +1,14 @@
// rustfmt-newline_style: Windows
#[macro_export]
macro_rules! hmmm___ffi_error {
($result:ident) => {
pub struct $result {
success: bool,
}
impl $result {
pub fn foo(self) {}
}
};
}