go/src/flag
Brad Fitzpatrick e1f38ccab1 flag: make default Usage prefer CommandLine's output over just os.Stderr
CommandLine (exported in Go 1.2) has default output of os.Stderr.

Before it was exported, it made sense to have the global Usage func
(the implicit usage func if CommandLine.Usage is nil) hard-code
os.Stderr has its output. But once CommandLine was exported, Usage
should use it if provided.

Fixes #20998

Change-Id: I9e1c0415a563a982634b9808199c9ee175d72f4c
Reviewed-on: https://go-review.googlesource.com/48390
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Rob Pike <r@golang.org>
2017-08-08 01:47:47 +00:00
..
example_test.go
export_test.go flag: make default Usage prefer CommandLine's output over just os.Stderr 2017-08-08 01:47:47 +00:00
flag.go flag: make default Usage prefer CommandLine's output over just os.Stderr 2017-08-08 01:47:47 +00:00
flag_test.go flag: make default Usage prefer CommandLine's output over just os.Stderr 2017-08-08 01:47:47 +00:00