WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Commit 743ebfd

Browse files
committed
Normative: make re-exporting a namespace object in 2 steps behave like 1 step
1 parent e936549 commit 743ebfd

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

spec.html

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28335,10 +28335,11 @@ <h1>
2833528335
1. If _importedBoundNames_ does not contain _ee_.[[LocalName]], then
2833628336
1. Append _ee_ to _localExportEntries_.
2833728337
1. Else,
28338+
1. NOTE: When exporting a binding or namespace object which was originally imported from another module, the ExportEntry Record is rewritten to match the form it would have if the binding or namespace object had been re-exported directly from the original module rather than imported then exported. This allows conflicts which arise from importing the same binding or namespace twice under the same name to be ignored rather than being treated as ambiguous.
2833828339
1. Let _ie_ be the element of _importEntries_ whose [[LocalName]] is _ee_.[[LocalName]].
2833928340
1. If _ie_.[[ImportName]] is ~namespace-object~, then
2834028341
1. NOTE: This is a re-export of an imported module namespace object.
28341-
1. Append _ee_ to _localExportEntries_.
28342+
1. Append the ExportEntry Record { [[ModuleRequest]]: _ie_.[[ModuleRequest]], [[ImportName]]: ~all~, [[LocalName]]: *null*, [[ExportName]]: _ee_.[[ExportName]] } to _indirectExportEntries_.
2834228343
1. Else,
2834328344
1. NOTE: This is a re-export of a single name.
2834428345
1. Append the ExportEntry Record { [[ModuleRequest]]: _ie_.[[ModuleRequest]], [[ImportName]]: _ie_.[[ImportName]], [[LocalName]]: *null*, [[ExportName]]: _ee_.[[ExportName]] } to _indirectExportEntries_.

0 commit comments

Comments
 (0)