We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 45c0be9 commit d9b4ab2Copy full SHA for d9b4ab2
common/kotlinx-coroutines-core-common/src/channels/Channel.kt
@@ -387,7 +387,7 @@ public fun <E> Channel(): Channel<E> = RendezvousChannel<E>()
387
*
388
* @throws IllegalArgumentException when [capacity] < -1
389
*/
390
-public fun <E> Channel(capacity: Int = 0): Channel<E> =
+public fun <E> Channel(capacity: Int = RENDEZVOUS): Channel<E> =
391
when (capacity) {
392
RENDEZVOUS -> RendezvousChannel()
393
UNLIMITED -> LinkedListChannel()
0 commit comments