Index: src/objects-inl.h |
diff --git a/src/objects-inl.h b/src/objects-inl.h |
index b1cfceea7742c36b479aa1c5e75d91677e42244d..b72a94a52ea35fca5bd6e0c7c60d756bf1765be0 100644 |
--- a/src/objects-inl.h |
+++ b/src/objects-inl.h |
@@ -5719,6 +5719,17 @@ SMI_ACCESSORS(Module, flags, kFlagsOffset) |
BOOL_ACCESSORS(Module, flags, evaluated, kEvaluatedBit) |
ACCESSORS(Module, embedder_data, Object, kEmbedderDataOffset) |
+SharedFunctionInfo* Module::shared() const { |
+ return code()->IsSharedFunctionInfo() ? SharedFunctionInfo::cast(code()) |
+ : JSFunction::cast(code())->shared(); |
+} |
+ |
+ModuleInfo* Module::info() const { |
+ return shared()->scope_info()->ModuleDescriptorInfo(); |
+} |
+ |
+uint32_t Module::Hash() const { return Symbol::cast(shared()->name())->Hash(); } |
+ |
ACCESSORS(AccessorPair, getter, Object, kGetterOffset) |
ACCESSORS(AccessorPair, setter, Object, kSetterOffset) |
@@ -7961,14 +7972,6 @@ Object* ModuleInfoEntry::module_request() const { |
return get(kModuleRequestIndex); |
} |
-ModuleInfo* Module::info() const { |
- DisallowHeapAllocation no_gc; |
- SharedFunctionInfo* shared = code()->IsSharedFunctionInfo() |
- ? SharedFunctionInfo::cast(code()) |
- : JSFunction::cast(code())->shared(); |
- return shared->scope_info()->ModuleDescriptorInfo(); |
-} |
- |
FixedArray* ModuleInfo::module_requests() const { |
return FixedArray::cast(get(kModuleRequestsIndex)); |
} |