mirror of
https://github.com/mamoe/mirai.git
synced 2025-01-06 08:00:10 +08:00
Make inline
This commit is contained in:
parent
ce7c9f8c82
commit
10e6c51948
@ -34,7 +34,7 @@ fun ByteReadPacket.transferTo(outputStream: OutputStream) {
|
||||
}
|
||||
}
|
||||
|
||||
fun <R> ByteReadPacket.useBytes(
|
||||
inline fun <R> ByteReadPacket.useBytes(
|
||||
n: Int = remaining.toInt(),//not that safe but adequate
|
||||
block: (data: ByteArray, length: Int) -> R
|
||||
): R = ByteArrayPool.useInstance {
|
||||
|
Loading…
Reference in New Issue
Block a user