1/* 2 * Copyright (c) 2024 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16// enable ic 17var a = 0 18for (var i = 0; i < 10000; i++) { 19 a = a + a; 20} 21 22// case 1 23// test toString in holder. 24function t() {} 25var I = t.prototype 26I.toInt = function() {} 27I.toNumber = function() {} 28I.toString = function() {} 29print(Object.getOwnPropertyDescriptor(I, 'toString').enumerable) 30 31const o6 = { 32 ..."function", 33} 34print(Object.getOwnPropertyDescriptor(o6, 0).configurable) 35 36try { 37 const v2 = ("string").match(ArrayBuffer) 38 class C4 extends Array { 39 constructor(a6, a7) { 40 super() 41 try { 42 this.concat(ArrayBuffer, v2, ArrayBuffer); 43 return v2 44 } catch (e) {} 45 } 46 } 47 new C4(C4, C4); 48} catch(e) {}