More efficient Char(Int) in common, JS, and JS-IR

This commit is contained in:
Ilya Gorbunov
2021-04-12 16:55:36 +03:00
parent 8041c3aa1d
commit ce7092a638
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -22,7 +22,7 @@ public inline fun Char(code: Int): Char {
if (code < Char.MIN_VALUE.code || code > Char.MAX_VALUE.code) {
throw IllegalArgumentException("Invalid Char code: $code")
}
return Char(code.toUShort())
return code.toChar()
}
/**