On Mon, Jan 28, 2019 at 4:44 PM 伊藤和也 <kazya.ito.dr...@gmail.com> wrote:
>
> Questions:
> 1. As the name says, doesn't an unbuffered channel use a buffer?

Sorry, I'm not sure what you are asking.  An unbuffered channel does
not use a buffer.  A buffered channel does use a buffer.

> 2. If so, does an unbuffered channel use a stack to send and receive a value?

An unbuffered channel is a synchronization point between the sending
and receiving goroutine.  That is, the transfer only occurs when both
goroutines are ready.  The value is transferred directly from the
sending goroutine to the receiving goroutine.

> 3. As the name says, does an buffered channel use a buffer?

Yes.

Ian

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to