From 0163eea2f344092ca2e07ac2711527d3a94df114 Mon Sep 17 00:00:00 2001 From: Him188 Date: Sat, 18 Jan 2020 22:41:08 +0800 Subject: [PATCH] Remove .plus(Number) --- .../kotlin/net.mamoe.mirai/message/data/Message.kt | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/message/data/Message.kt b/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/message/data/Message.kt index 42a049cf5..e1c91eec4 100644 --- a/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/message/data/Message.kt +++ b/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/message/data/Message.kt @@ -86,19 +86,6 @@ interface Message { operator fun plus(another: String): MessageChain = this.followedBy(another.toString().toMessage()) // `+ ""` will be resolved to `plus(String)` instead of `plus(CharSeq)` operator fun plus(another: CharSequence): MessageChain = this.followedBy(another.toString().toMessage()) - - // do remove these primitive types, they can reduce boxing - operator fun plus(another: Int): MessageChain = this.followedBy(another.toString().toMessage()) - - operator fun plus(another: Double): MessageChain = this.followedBy(another.toString().toMessage()) - operator fun plus(another: Long): MessageChain = this.followedBy(another.toString().toMessage()) - operator fun plus(another: Short): MessageChain = this.followedBy(another.toString().toMessage()) - operator fun plus(another: Byte): MessageChain = this.followedBy(another.toString().toMessage()) - operator fun plus(another: Float): MessageChain = this.followedBy(another.toString().toMessage()) - - operator fun plus(another: Number): MessageChain = this.followedBy(another.toString().toMessage()) - - } /**