Summary: test262: Many module test regressions: TypeError: undefined is not an object (evaluating 'ns[Symbol.iterator].name') Reduced Test: (save as mod.js) > import * as ns from './mod.js'; > print(ns[Symbol.iterator]); Steps to Reproduce: > $ jsc --module-file=mod.js Produces undefined, but expected it to be a function. Failing tests: test262.yaml/test262/test/language/module-code/namespace/Symbol.iterator/length.js.default: Exception: TypeError: undefined is not an object (evaluating 'ns[Symbol.iterator].length') test262.yaml/test262/test/language/module-code/namespace/Symbol.iterator/list-iter-next-length.js.default: Exception: TypeError: ns[Symbol.iterator] is not a function. (In 'ns[Symbol.iterator]()', 'ns[Symbol.iterator]' is undefined) test262.yaml/test262/test/language/module-code/namespace/Symbol.iterator/list-iter-next-name.js.default: Exception: TypeError: ns[Symbol.iterator] is not a function. (In 'ns[Symbol.iterator]()', 'ns[Symbol.iterator]' is undefined) test262.yaml/test262/test/language/module-code/namespace/Symbol.iterator/list-iter-next-prop-desc.js.default: Exception: TypeError: ns[Symbol.iterator] is not a function. (In 'ns[Symbol.iterator]()', 'ns[Symbol.iterator]' is undefined) test262.yaml/test262/test/language/module-code/namespace/Symbol.iterator/name.js.default: Exception: TypeError: undefined is not an object (evaluating 'ns[Symbol.iterator].name') test262.yaml/test262/test/language/module-code/namespace/Symbol.iterator/values-binding-types.js.default: Exception: TypeError: ns[Symbol.iterator] is not a function. (In 'ns[Symbol.iterator]()', 'ns[Symbol.iterator]' is undefined) test262.yaml/test262/test/language/module-code/namespace/Symbol.iterator/values-order.js.default: Exception: TypeError: ns[Symbol.iterator] is not a function. (In 'ns[Symbol.iterator]()', 'ns[Symbol.iterator]' is undefined)
I suspect this is actually expected as a result of: r212430 <http://trac.webkit.org/changeset/212430> [JSC] Update module namespace object according to the latest ECMA262 https://bugs.webkit.org/show_bug.cgi?id=168280 > Reflect updates to the module namespace object. > > 1. @@iterator property is dropped. > 2. @@toStringTag property becomes non-configurable. > 3. delete with Symbol should be delegated to the JSObject's one. In which case we should probably just mark these test262 tests as expecting to fail.
Yep, I'll update expectations.
Created attachment 306359 [details] [PATCH] Proposed Fix
I'm going to see if I can add a way to add: :failDueToOutdatedTest So that we will know this isn't a failure we need to fix on our end. I just found some other tests are also ES2017 progressions that I'll want to mark the same way.
Created attachment 306363 [details] [PATCH] For Landing
Comment on attachment 306363 [details] [PATCH] For Landing Clearing flags on attachment: 306363 Committed r214985: <http://trac.webkit.org/changeset/214985>