diff options
| author | Seebs <seebs@sourcegraph.com> | 2018-08-03 11:50:55 -0500 |
|---|---|---|
| committer | Tobias Klauser <tobias.klauser@gmail.com> | 2018-08-24 07:11:38 +0000 |
| commit | 9cfa41c826ba358dc6f911f72dfbfda8c13d27fe (patch) | |
| tree | 199b2e68fd518d31e8007b5f2437ed1f355bbe83 /src | |
| parent | c907a75494f0d828a9afa5f849684f3c09c4afa2 (diff) | |
| download | go-9cfa41c826ba358dc6f911f72dfbfda8c13d27fe.tar.xz | |
os: use Println instead of Printf in example
This message has no format specifiers and no trailing newline.
It should use Println for consistency with other examples.
Change-Id: I49bd1652f9449fcbdd79c6b689c123090972aab3
Reviewed-on: https://go-review.googlesource.com/127836
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Diffstat (limited to 'src')
| -rw-r--r-- | src/os/example_test.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/os/example_test.go b/src/os/example_test.go index e21415a3fd..95a4a67817 100644 --- a/src/os/example_test.go +++ b/src/os/example_test.go @@ -70,7 +70,7 @@ func ExampleFileMode() { func ExampleIsNotExist() { filename := "a-nonexistent-file" if _, err := os.Stat(filename); os.IsNotExist(err) { - fmt.Printf("file does not exist") + fmt.Println("file does not exist") } // Output: // file does not exist |
