diff options
author | Brian Smith <brian@dbsoft.org> | 2023-04-18 11:00:34 -0500 |
---|---|---|
committer | Brian Smith <brian@dbsoft.org> | 2023-04-27 13:34:05 -0500 |
commit | c961285752dd16bc0e2ef53dc4b06ce609b439e0 (patch) | |
tree | c4ec7cedadca49e177a8c98fe22f2b525ddad294 /js/src/builtin/ModuleObject.cpp | |
parent | a28f3edf2a081c26a60236cc151a29d2ca99998f (diff) | |
download | uxp-c961285752dd16bc0e2ef53dc4b06ce609b439e0.tar.gz |
Issue #1691 - Part 6e: Fix problems due to divergent codebases. This gets basic dynamic import working.
Fix a problem in Part 5b where Mozilla used toGCThing() and we don't.
Fix a problem in Part 4 where runtime() returns nullptr in our codebase since it runs on JS Helper thread.
We need to get the runtime via runtimeFromAnyThread() instead.
(cherry picked from commit dddb46225bbd1adff11f635e32934aee36923e47)
Diffstat (limited to 'js/src/builtin/ModuleObject.cpp')
-rw-r--r-- | js/src/builtin/ModuleObject.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/js/src/builtin/ModuleObject.cpp b/js/src/builtin/ModuleObject.cpp index 5efd594b62..8e01ea2ac8 100644 --- a/js/src/builtin/ModuleObject.cpp +++ b/js/src/builtin/ModuleObject.cpp @@ -842,7 +842,7 @@ ModuleObject::maybeScript() const if (value.isUndefined()) return nullptr; - return value.toGCThing()->as<JSScript>(); + return static_cast<JSScript*>(value.toPrivate()); } JSScript* |