-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
module runtime change #3 #432
Conversation
mainly ResolveExport and GetExportNames operations. Start implementation of ModuleNamespace. Implemented GetModuleNamespace. Detailed namespace implementation is not in yet. Filled in some holes in earlier implementation, like error handling for top level operations, notify the parent module if the current module failed in parse or ModuleDeclarationInitialization. Export method for bytecode generator to retrieve the localexport slot information. Fixed some potential memory leak by implementing the Finalize method for SourceTextModuleRecord. Temporary disable ModuleEvaluation for non-root modules, pending bytecode generator change.
@pleath @boingoing @abchatra can you take a look? |
PropertyId exportedNameId = EnsurePropertyIdForIdentifier(exportEntry.exportName); | ||
localNames->Prepend(exportedNameId); | ||
}); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you feel strongly about merging these three lists of exports (indirectExportRecordList, localExportRecordList, starExportRecordList) ? Should be possible to determine which type of export without keeping them in different lists if duplicating this code becomes troublesome.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
{AncestorPath = 54950339}
currently I'm not copying those lists, and it's better to keep them separate for different operations. We can change if perf becomes an issue here.
Looks good to me! Big change to module record, almost support everything besides namespace object. Cool! |
|
||
//virtual int GetPropertyCount() override; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are you keeping the commented lines on purpose?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are unimplemented feature. We'll uncomment these in upcoming changes.
In reply to: 55074978 [](ancestors = 55074978)
Merge pull request #432 from Yongqu:module Implement the remaining operations in SourceTextModuleRecord, including mainly ResolveExport and GetExportNames operations. Start implementation of ModuleNamespace. Implemented GetModuleNamespace. Detailed namespace implementation is not in yet. Filled in some holes in earlier implementation, like error handling for top level operations, notify the parent module if the current module failed in parse or ModuleDeclarationInitialization. Export method for bytecode generator to retrieve the localexport slot information. Fixed some potential memory leak by implementing the Finalize method for SourceTextModuleRecord. Temporary disable ModuleEvaluation for non-root modules, pending bytecode generator change.
Implement the remaining operations in SourceTextModuleRecord, including mainly ResolveExport and GetExportNames operations. Start implementation of ModuleNamespace. Implemented GetModuleNamespace. Detailed namespace implementation is not in yet. Filled in some holes in earlier implementation, like error handling for top level operations, notify the parent module if the current module failed in parse or ModuleDeclarationInitialization. Export method for bytecode generator to retrieve the localexport slot information. Fixed some potential memory leak by implementing the Finalize method for SourceTextModuleRecord. Temporary disable ModuleEvaluation for non-root modules, pending bytecode generator change.