Is Channel::send thread-safe?

The documentation of send method for Channel says:

Cancellation of suspended send is atomic

But is the addition of a new element to the Channel atomic itself? I mean if two coroutines try to send at the same time, can that produce a race condition?

1 Like

Yes, the whole interface is thread safe.

1 Like

Please, where can I read to prove to myself the whole interface is threadsafe?

1 Like