]> Cypherpunks.ru repositories - gostls13.git/commit
fmt: unify the printing examples
authorRob Pike <r@golang.org>
Thu, 20 Sep 2018 23:47:31 +0000 (09:47 +1000)
committerRob Pike <r@golang.org>
Mon, 24 Sep 2018 21:15:52 +0000 (21:15 +0000)
commit5be78668ef311576c945c4dfc6cfb0716236a89f
tree134f2a05fe22daee02b41f9d342a53927a823450
parent206fd7886b717d49758de9c125c1fd3575d74ef6
fmt: unify the printing examples

Provide an example for each of the printing functions (Print,
Sprintf, Fprintln etc.), and make them all produce the same output
so their usage can be compared.

Also add a package-level example explaining the difference between
how Printf, Println, and Print behave.

There are more examples to come.

Update #27554.

Change-Id: Ide03e5233f3762a9ee2ac0269f534ab927562ce2
Reviewed-on: https://go-review.googlesource.com/136615
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
src/fmt/example_test.go