use

suspend fun ByteWriteChannel.use(
    block: suspend ByteWriteChannel.() -> Unit
): Unit

Deprecated:

inline fun ByteWriteChannel.use(
    block: ByteWriteChannel.() -> Unit
): Unit

Executes block on ByteWriteChannel and close it down correctly whether an exception