Update the module loader load API in preparation for loading ES6 modules in mozJSComponentLoader
Categories
(Core :: JavaScript Engine, task)
Tracking
()
Tracking | Status | |
---|---|---|
firefox102 | --- | fixed |
People
(Reporter: jonco, Assigned: jonco)
References
Details
Attachments
(5 files)
Assignee | ||
Comment 1•2 years ago
|
||
Give the caching interfaces default empty implementations so derived classes
don't need to implement them if they don't want any speical behaviour. We don't
use these methods for caching in mozJSComponentLoader.
Assignee | ||
Comment 2•2 years ago
|
||
Classes with virtual methods should have a virtual destructor so deleting an
object through a base class pointer works correctly. I think I got lint
warnings about this when I added a new derived loader.
Depends on D145488
Assignee | ||
Comment 3•2 years ago
|
||
Module loaders require an event target to use with mozPromise. The default uses
the event loop so doesn't permit implementing a synchronous module loader.
Depends on D145489
Assignee | ||
Comment 4•2 years ago
|
||
This allows derived loaders not to support dynamic import if they don't want to.
Module loading for in mozJSComponentLoader will not initially support this.
Depends on D145490
Assignee | ||
Comment 5•2 years ago
|
||
The main version of EvaluateModule will continue to use AutoEntryScript, but we
don't always want it's error reporting behaviour.
Depends on D145491
Updated•2 years ago
|
Pushed by jcoppeard@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/b3a61b8f69f1 Part 1: Give ScriptLoaderInterface caching methods default implementations which do nothing r=yulia https://hg.mozilla.org/integration/autoland/rev/bb4df70de2f3 Part 2: Give ScriptLoaderInterface a virtual destructor r=yulia https://hg.mozilla.org/integration/autoland/rev/a0d9dae70a33 Part 3: Add the option for derived module loaders to specifiy their own event target r=yulia https://hg.mozilla.org/integration/autoland/rev/c0f8b8d263c9 Part 4: Throw an error if CreateDynamicImport returns null r=yulia https://hg.mozilla.org/integration/autoland/rev/d741a6c430de Part 5: Add EvaluateModuleInContext method to allow callers to set up and supply their own JSContext r=yulia
Comment 7•2 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/b3a61b8f69f1
https://hg.mozilla.org/mozilla-central/rev/bb4df70de2f3
https://hg.mozilla.org/mozilla-central/rev/a0d9dae70a33
https://hg.mozilla.org/mozilla-central/rev/c0f8b8d263c9
https://hg.mozilla.org/mozilla-central/rev/d741a6c430de
Description
•