From f1b1c000c2a05972c1834f306786d2b41f767ef5 Mon Sep 17 00:00:00 2001 From: Fabrice Bellard Date: Sat, 28 Jun 2025 10:43:26 +0200 Subject: [PATCH] update test262 --- TODO | 4 ++-- test262.conf | 2 ++ test262_errors.txt | 12 ++++++------ tests/test262.patch | 23 ++++++++--------------- 4 files changed, 18 insertions(+), 23 deletions(-) diff --git a/TODO b/TODO index 8d0ff43..5caa38d 100644 --- a/TODO +++ b/TODO @@ -62,5 +62,5 @@ Optimization ideas: Test262o: 0/11262 errors, 463 excluded Test262o commit: 7da91bceb9ce7613f87db47ddd1292a2dda58b42 (es5-tests branch) -Result: 46/79346 errors, 1617 excluded, 6754 skipped -Test262 commit: 4b5d36ab6ef2f59d0a8902cd383762547a3a74c4 +Result: 48/79398 errors, 1637 excluded, 6771 skipped +Test262 commit: 1e38cbeb1c878a352b55c3ebe03ee8eda74a33ed diff --git a/test262.conf b/test262.conf index 3277594..c099f2f 100644 --- a/test262.conf +++ b/test262.conf @@ -337,6 +337,8 @@ test262/test/staging/sm/RegExp/source.js test262/test/staging/sm/RegExp/escape.js # source directives are not standard yet test262/test/staging/sm/syntax/syntax-parsed-arrow-then-directive.js +# returning "bound fn" as initialName for a function is permitted by the spec +test262/test/staging/sm/Function/function-toString-builtin.js [tests] # list test files or use config.testdir diff --git a/test262_errors.txt b/test262_errors.txt index 7dd3f76..1b541f2 100644 --- a/test262_errors.txt +++ b/test262_errors.txt @@ -9,15 +9,15 @@ test262/test/staging/sm/Function/arguments-parameter-shadowing.js:15: Test262Err test262/test/staging/sm/Function/constructor-binding.js:12: Test262Error: Expected SameValue(«"function"», «"undefined"») to be true test262/test/staging/sm/Function/function-bind.js:14: Test262Error: Conforms to NativeFunction Syntax: "function bound unbound() {\n [native code]\n}" test262/test/staging/sm/Function/function-name-for.js:12: Test262Error: Expected SameValue(«""», «"forInHead"») to be true -test262/test/staging/sm/Function/function-toString-builtin.js:14: Test262Error: Expected match to '/^\s*function\s*(get|set)?\s*(\w+|(?:'[^']*')|(?:"[^"]*")|\d+|(?:\[[^\]]+\]))?\s*\(\s*\)\s*\{\s*\[native code\]\s*\}\s*$/', Actual value 'function bound fn() { - [native code] -}' Expected SameValue(«null», «null») to be false test262/test/staging/sm/Function/implicit-this-in-parameter-expression.js:13: Test262Error: Expected SameValue(«[object Object]», «undefined») to be true test262/test/staging/sm/Function/invalid-parameter-list.js:35: Error: Assertion failed: expected exception SyntaxError, no exception thrown test262/test/staging/sm/RegExp/constructor-ordering-2.js:15: Test262Error: Expected SameValue(«false», «true») to be true -test262/test/staging/sm/RegExp/regress-613820-1.js:13: Test262Error: Expected SameValue(«"aaa"», «"aa"») to be true -test262/test/staging/sm/RegExp/regress-613820-2.js:13: Test262Error: Expected SameValue(«"f"», «undefined») to be true -test262/test/staging/sm/RegExp/regress-613820-3.js:13: Test262Error: Expected SameValue(«"aab"», «"aa"») to be true +test262/test/staging/sm/RegExp/regress-613820-1.js:12: Test262Error: Actual [aaa, aa, a] and expected [aa, a, a] should have the same contents. +test262/test/staging/sm/RegExp/regress-613820-1.js:12: strict mode: Test262Error: Actual [aaa, aa, a] and expected [aa, a, a] should have the same contents. +test262/test/staging/sm/RegExp/regress-613820-2.js:12: Test262Error: Actual [foobar, f, o, o, b, a, r] and expected [foobar, undefined, undefined, undefined, b, a, r] should have the same contents. +test262/test/staging/sm/RegExp/regress-613820-2.js:12: strict mode: Test262Error: Actual [foobar, f, o, o, b, a, r] and expected [foobar, undefined, undefined, undefined, b, a, r] should have the same contents. +test262/test/staging/sm/RegExp/regress-613820-3.js:12: Test262Error: Actual [aab, a, undefined, ab] and expected [aa, undefined, a, undefined] should have the same contents. +test262/test/staging/sm/RegExp/regress-613820-3.js:12: strict mode: Test262Error: Actual [aab, a, undefined, ab] and expected [aa, undefined, a, undefined] should have the same contents. test262/test/staging/sm/TypedArray/constructor-buffer-sequence.js:73: Error: Assertion failed: expected exception ExpectedError, got Error: Poisoned Value test262/test/staging/sm/TypedArray/prototype-constructor-identity.js:17: Test262Error: Expected SameValue(«2», «6») to be true test262/test/staging/sm/TypedArray/set-detached-bigint.js:27: Error: Assertion failed: expected exception SyntaxError, got RangeError: invalid array length diff --git a/tests/test262.patch b/tests/test262.patch index 4ed0afb..6956d15 100644 --- a/tests/test262.patch +++ b/tests/test262.patch @@ -71,10 +71,10 @@ index b397be0..c197ddc 100644 return result; } diff --git a/harness/sm/non262.js b/harness/sm/non262.js -index c1829e3..3a3ee27 100644 +index 89df923..79ded15 100644 --- a/harness/sm/non262.js +++ b/harness/sm/non262.js -@@ -41,8 +41,6 @@ globalThis.createNewGlobal = function() { +@@ -34,8 +34,6 @@ globalThis.createNewGlobal = function() { return $262.createRealm().global } @@ -83,15 +83,8 @@ index c1829e3..3a3ee27 100644 function assertEq(...args) { assert.sameValue(...args) } -@@ -71,4 +69,4 @@ if (globalThis.createExternalArrayBuffer === undefined) { - if (globalThis.enableGeckoProfilingWithSlowAssertions === undefined) { - globalThis.enableGeckoProfilingWithSlowAssertions = globalThis.enableGeckoProfiling = - globalThis.disableGeckoProfiling = () => {} --} -\ No newline at end of file -+} diff --git a/test/staging/sm/extensions/regress-469625-01.js b/test/staging/sm/extensions/regress-469625-01.js -index 5b62aeb..da07aae 100644 +index 81f84fc..4652002 100644 --- a/test/staging/sm/extensions/regress-469625-01.js +++ b/test/staging/sm/extensions/regress-469625-01.js @@ -14,8 +14,7 @@ esid: pending @@ -104,17 +97,17 @@ index 5b62aeb..da07aae 100644 //----------------------------------------------------------------------------- -@@ -27,9 +26,6 @@ function test() - printBugNumber(BUGNUMBER); - printStatus (summary); - +@@ -24,9 +23,6 @@ test(); + + function test() + { - expect = 'TypeError: [].__proto__ is not a function'; - - Array.prototype.__proto__ = function () { return 3; }; try -@@ -38,8 +34,10 @@ function test() +@@ -35,8 +31,10 @@ function test() } catch(ex) {