]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/go: fix doc about examples with empty Output
authorAlberto Donizetti <alb.donizetti@gmail.com>
Fri, 16 Dec 2016 08:58:06 +0000 (09:58 +0100)
committerBrad Fitzpatrick <bradfitz@golang.org>
Mon, 19 Dec 2016 17:32:08 +0000 (17:32 +0000)
Fixes #18191

Change-Id: Ic2bac9d2a6f42d14e780c74d9c842ee344ab030a
Reviewed-on: https://go-review.googlesource.com/34512
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
src/cmd/go/alldocs.go
src/cmd/go/test.go

index b4807420b076bb66579acd5d9591e5b4d12aad3f..bf597c03833229ccb67ab4a78eb666e4b9c52858 100644 (file)
 // is compared exactly against the comment (see examples below). If the last
 // comment begins with "Unordered output:" then the output is compared to the
 // comment, however the order of the lines is ignored. An example with no such
-// comment, or with no text after "Output:" is compiled but not executed.
+// comment is compiled but not executed. An example with no text after
+// "Output:" is compiled, executed, and expected to produce no output.
 //
 // Godoc displays the body of ExampleXXX to demonstrate the use
 // of the function, constant, or variable XXX.  An example of a method M with
index f27144c48557790a7e9f3e852b18936a8a1d75ea..e0c0d6088cbe45e1d1d67e4bcb2b8e4f9a7443e5 100644 (file)
@@ -334,7 +334,8 @@ If the last comment in the function starts with "Output:" then the output
 is compared exactly against the comment (see examples below). If the last
 comment begins with "Unordered output:" then the output is compared to the
 comment, however the order of the lines is ignored. An example with no such
-comment, or with no text after "Output:" is compiled but not executed.
+comment is compiled but not executed. An example with no text after
+"Output:" is compiled, executed, and expected to produce no output.
 
 Godoc displays the body of ExampleXXX to demonstrate the use
 of the function, constant, or variable XXX.  An example of a method M with