From bb0d4a4fc617b47ca1abcf3f3b3f8852f72f28bc Mon Sep 17 00:00:00 2001 From: Alexey Andreev Date: Sat, 21 Oct 2023 19:19:55 +0200 Subject: [PATCH] JS: remove old polyfill --- .../org/teavm/backend/javascript/runtime.js | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/core/src/main/resources/org/teavm/backend/javascript/runtime.js b/core/src/main/resources/org/teavm/backend/javascript/runtime.js index c1bede99b..c186a4d36 100644 --- a/core/src/main/resources/org/teavm/backend/javascript/runtime.js +++ b/core/src/main/resources/org/teavm/backend/javascript/runtime.js @@ -56,22 +56,6 @@ function $rt_castToClass(obj, cls) { } return obj; } -Array.prototype.fill = Array.prototype.fill || function(value,start,end) { - var len = this.length; - if (!len) return this; - start = start | 0; - var i = start < 0 - ? Math.max(len + start, 0) - : Math.min(start, len); - end = end === undefined ? len : end | 0; - end = end < 0 - ? Math.max(len + end, 0) - : Math.min(end, len); - for (; i < end; i++) { - this[i] = value; - } - return this; -}; function $rt_createArray(cls, sz) { var data = new Array(sz); data.fill(null);