From 0768f8d369bf446ab7003e93819bebaf410ab6d4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bartek=20Iwa=C5=84czuk?= Date: Wed, 19 May 2021 20:53:43 +0200 Subject: refactor(core): move ModuleMap to separate RefCell (#10656) This commit moves bulk of the logic related to module loading from "JsRuntime" to "ModuleMap". Next steps are to rewrite the actual loading logic (represented by "RecursiveModuleLoad") to be a part of "ModuleMap" as well -- that way we will be able to track multiple module loads from within the map which should help me solve the problem of concurrent loads (since all info about currently loading/loaded modules will be contained in the ModuleMap, so we'll be able to know if actually all required modules have been loaded). --- core/lib.rs | 2 ++ 1 file changed, 2 insertions(+) (limited to 'core/lib.rs') diff --git a/core/lib.rs b/core/lib.rs index 1f75b0ee3..90b2cdfc4 100644 --- a/core/lib.rs +++ b/core/lib.rs @@ -51,6 +51,8 @@ pub use crate::modules::ModuleLoader; pub use crate::modules::ModuleSource; pub use crate::modules::ModuleSourceFuture; pub use crate::modules::NoopModuleLoader; +// TODO(bartlomieju): this struct should be implementation +// detail nad not be public pub use crate::modules::RecursiveModuleLoad; pub use crate::normalize_path::normalize_path; pub use crate::ops::serialize_op_result; -- cgit v1.2.3