[K/JS] Use declared upper-bound types for parameters inside inlined functions body, instead of the provided types
This commit is contained in:
@@ -1623,9 +1623,20 @@ object ArrayOps : TemplateGroupBase() {
|
||||
body {
|
||||
"""
|
||||
AbstractList.checkRangeIndexes(fromIndex, toIndex, size)
|
||||
nativeFill(element, fromIndex, toIndex);
|
||||
nativeFill(element, fromIndex, toIndex)
|
||||
"""
|
||||
}
|
||||
specialFor(ArraysOfPrimitives) {
|
||||
if (primitive == PrimitiveType.Char) {
|
||||
body {
|
||||
"""
|
||||
AbstractList.checkRangeIndexes(fromIndex, toIndex, size)
|
||||
// We need to call [Char.code] here to eliminate Char-boxing with the new JS function inlining logic
|
||||
nativeFill(element.code, fromIndex, toIndex)
|
||||
"""
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
on(Platform.Native) {
|
||||
suppress("ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS")
|
||||
|
||||
Reference in New Issue
Block a user