From 797567968eeb3b14d08a0446e3716a29c1ace287 Mon Sep 17 00:00:00 2001 From: nu50218 Date: Thu, 12 Mar 2020 06:19:50 +0000 Subject: [PATCH] go/analysis/singlechecker: append a newline after "Flags:" MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Currently `flag.Usage` set in `Main` prints a message as follows, ``` ⋮ Flags: -V print version and exit ⋮ ``` but this should be ``` ⋮ Flags: -V print version and exit ⋮ ``` It seems this is caused by [this](https://go-review.googlesource.com/c/tools/+/162717). Change-Id: Ida7223e87677da4b5f280708213a526b5973ce78 GitHub-Last-Rev: ed2729641cc564c66689fd959fdbcc341b9e7c77 GitHub-Pull-Request: golang/tools#213 Reviewed-on: https://go-review.googlesource.com/c/tools/+/223123 Reviewed-by: Michael Matloob Run-TryBot: Michael Matloob TryBot-Result: Gobot Gobot --- go/analysis/singlechecker/singlechecker.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/go/analysis/singlechecker/singlechecker.go b/go/analysis/singlechecker/singlechecker.go index bd207d0fd2..500a40a58d 100644 --- a/go/analysis/singlechecker/singlechecker.go +++ b/go/analysis/singlechecker/singlechecker.go @@ -56,7 +56,7 @@ func Main(a *analysis.Analyzer) { if len(paras) > 1 { fmt.Fprintln(os.Stderr, strings.Join(paras[1:], "\n\n")) } - fmt.Fprintf(os.Stderr, "\nFlags:") + fmt.Fprintln(os.Stderr, "\nFlags:") flag.PrintDefaults() }