Commit 2551cf9d authored by Andrew Gerrand's avatar Andrew Gerrand

go_mem: clarified unbuffered channel sync example

R=rsc
CC=golang-dev
https://golang.org/cl/218063
parent b0fba898
......@@ -190,7 +190,8 @@ the send on that channel completes.
</p>
<p>
This program:
This program (as above, but with the send and receive statements swapped and
using an unbuffered channel):
</p>
<pre>
......@@ -222,7 +223,7 @@ before the <code>print</code>.
If the channel were buffered (e.g., <code>c = make(chan int, 1)</code>)
then the program would not be guaranteed to print
<code>"hello, world"</code>. (It might print the empty string;
it cannot print <code>"hello, sailor"</code>, nor can it crash.)
it cannot print <code>"goodbye, universe"</code>, nor can it crash.)
</p>
<h3>Locks</h3>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment