From 5ca444da2667c9040394b51aa102af96f1756b86 Mon Sep 17 00:00:00 2001 From: Him188 Date: Fri, 3 Jan 2020 17:32:49 +0800 Subject: [PATCH] Use supertype Input --- .../src/commonMain/kotlin/net.mamoe.mirai/utils/io/DebugUtil.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/utils/io/DebugUtil.kt b/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/utils/io/DebugUtil.kt index e6ecb2920..80e9253fd 100644 --- a/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/utils/io/DebugUtil.kt +++ b/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/utils/io/DebugUtil.kt @@ -51,7 +51,7 @@ fun ByteReadPacket.debugPrint(name: String = ""): ByteReadPacket { } } -inline fun ByteReadPacket.debugPrintIfFail(name: String = "", block: ByteReadPacket.() -> R): R { +inline fun Input.debugPrintIfFail(name: String = "", block: ByteReadPacket.() -> R): R { ByteArrayPool.useInstance { val count = this.readAvailable(it) try {