Issue #618 - Update code comments for ModuleInstantiate

This commit is contained in:
Moonchild 2020-07-03 14:05:40 +00:00 committed by Roy Tam
commit 7b30bfee4c
2 changed files with 2 additions and 2 deletions

View file

@ -8261,7 +8261,7 @@ BytecodeEmitter::emitFunction(ParseNode* pn, bool needsProto)
if (topLevelFunction) {
if (sc->isModuleContext()) {
// For modules, we record the function and instantiate the binding
// during ModuleDeclarationInstantiation(), before the script is run.
// during ModuleInstantiate(), before the script is run.
RootedModuleObject module(cx, sc->asModuleContext()->module());
if (!module->noteFunctionDeclaration(cx, name, fun))

View file

@ -5038,7 +5038,7 @@ Parser<FullParseHandler>::namedImportsOrNamespaceImport(TokenKind tt, Node impor
// Namespace imports are are not indirect bindings but lexical
// definitions that hold a module namespace object. They are treated
// as const variables which are initialized during the
// ModuleDeclarationInstantiation step.
// ModuleInstantiate step.
RootedPropertyName bindingName(context, importedBinding());
if (!bindingName)
return false;