From 8f563226942570490ca77ea5ebfcc19fb3cf4089 Mon Sep 17 00:00:00 2001 From: Oliver Schneider Date: Fri, 18 Aug 2017 12:46:28 +0200 Subject: Add an additional empty line between the suggested `use` and the next item --- src/librustc_errors/lib.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/librustc_errors') diff --git a/src/librustc_errors/lib.rs b/src/librustc_errors/lib.rs index 3459771459a..26dda2dc42d 100644 --- a/src/librustc_errors/lib.rs +++ b/src/librustc_errors/lib.rs @@ -217,8 +217,10 @@ impl CodeSuggestion { if !buf.ends_with('\n') { push_trailing(buf, prev_line.as_ref(), &prev_hi, None); } - // remove trailing newline - buf.pop(); + // remove trailing newlines + while buf.ends_with('\n') { + buf.pop(); + } } bufs } -- cgit 1.4.1-3-g733a5