From 9cfa41c826ba358dc6f911f72dfbfda8c13d27fe Mon Sep 17 00:00:00 2001 From: Seebs Date: Fri, 3 Aug 2018 11:50:55 -0500 Subject: [PATCH] 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 Reviewed-by: Tobias Klauser Run-TryBot: Brad Fitzpatrick TryBot-Result: Gobot Gobot --- src/os/example_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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 -- 2.50.0