Skip to content

Commit

Permalink
Bug 1326453 - Part 2: Change @@toStringTag for module namespace objec…
Browse files Browse the repository at this point in the history
…ts to non-configurable
  • Loading branch information
janekptacijarabaci authored and roytam1 committed Nov 11, 2019
1 parent 99f20bd commit 307c8cb
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion js/src/builtin/ModuleObject.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -394,7 +394,7 @@ ModuleNamespaceObject::ProxyHandler::getOwnPropertyDescriptor(JSContext* cx, Han
desc.object().set(proxy);
desc.setWritable(false);
desc.setEnumerable(false);
desc.setConfigurable(true);
desc.setConfigurable(false);
desc.setValue(value);
return true;
}
Expand Down
2 changes: 1 addition & 1 deletion js/src/jit-test/tests/modules/import-namespace.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ desc = Object.getOwnPropertyDescriptor(ns, Symbol.toStringTag);
assertEq(desc.value, "Module");
assertEq(desc.writable, false);
assertEq(desc.enumerable, false);
assertEq(desc.configurable, true);
assertEq(desc.configurable, false);
assertEq(typeof desc.get, "undefined");
assertEq(typeof desc.set, "undefined");
assertEq(Object.prototype.toString.call(ns), "[object Module]");
Expand Down

0 comments on commit 307c8cb

Please sign in to comment.