[JS IR] stdlib: generate type-safe contentToString for primitive arrays
Avoid casting 'primitive' arrays to Array<*> because they fail on runtime
This commit is contained in:
@@ -206,7 +206,7 @@ object ArrayOps : TemplateGroupBase() {
|
||||
body { "definedExternally" }
|
||||
}
|
||||
on(Backend.IR) {
|
||||
body { "return arrayToString(this as Array<*>)" }
|
||||
body { """return joinToString(", ", "[", "]")""" }
|
||||
}
|
||||
}
|
||||
on(Platform.Native) {
|
||||
|
||||
Reference in New Issue
Block a user