summaryrefslogtreecommitdiff
path: root/core/modules.rs
diff options
context:
space:
mode:
authorSatya Rohith <me@satyarohith.com>2023-01-29 16:09:43 +0400
committerGitHub <noreply@github.com>2023-01-29 17:39:43 +0530
commit2c7855014498eeae4543aaf6934d3f2bcc818b79 (patch)
tree43068a617d8406a497e4e3c9c6f8d11ed18573cb /core/modules.rs
parent50ba8ae6b2c23467e67d71c204a09c569166ee27 (diff)
refactor(core): derive equality traits for `ResolutionKind` enum (#17578)
The commit derives Eq, PartialEq, and Debug traits for the `ResolutionKind` enum to make it possible for external implementors to assert ResolutionKind.
Diffstat (limited to 'core/modules.rs')
-rw-r--r--core/modules.rs1
1 files changed, 1 insertions, 0 deletions
diff --git a/core/modules.rs b/core/modules.rs
index 9a7445959..19d1f4fb2 100644
--- a/core/modules.rs
+++ b/core/modules.rs
@@ -204,6 +204,7 @@ pub type ModuleSourceFuture = dyn Future<Output = Result<ModuleSource, Error>>;
type ModuleLoadFuture =
dyn Future<Output = Result<(ModuleRequest, ModuleSource), Error>>;
+#[derive(Debug, PartialEq, Eq)]
pub enum ResolutionKind {
/// This kind is used in only one situation: when a module is loaded via
/// `JsRuntime::load_main_module` and is the top-level module, ie. the one