Skip to content

Commit

Permalink
fix 'left behind trailing whitespace' (#3761)
Browse files Browse the repository at this point in the history
  • Loading branch information
rchaser53 authored and topecongiro committed Sep 5, 2019
1 parent 783948f commit 1ded995
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/visitor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -623,7 +623,7 @@ impl<'b, 'a: 'b> FmtVisitor<'a> {
self.push_str(s);
} else {
let snippet = self.snippet(span);
self.push_str(snippet);
self.push_str(snippet.trim());
}
self.last_pos = source!(self, span).hi();
}
Expand Down
5 changes: 5 additions & 0 deletions tests/target/issue-3741.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
pub enum PublishedFileVisibility {
Public = sys::ERemoteStoragePublishedFileVisibility_k_ERemoteStoragePublishedFileVisibilityPublic as i32,
FriendsOnly = sys::ERemoteStoragePublishedFileVisibility_k_ERemoteStoragePublishedFileVisibilityFriendsOnly as i32,
Private = sys::ERemoteStoragePublishedFileVisibility_k_ERemoteStoragePublishedFileVisibilityPrivate as i32,
}

0 comments on commit 1ded995

Please sign in to comment.