Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(16)

Unified Diff: src/ast/modules.cc

Issue 2465283004: [modules] Maintain array of cells for imports and local exports. (Closed)
Patch Set: Various changes. Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/ast/modules.cc
diff --git a/src/ast/modules.cc b/src/ast/modules.cc
index 44bffa7bd2c6d4787652916618a1b5ac9e207128..5bd3b9bd34b3ee2647035cbd1acb48a392536ca6 100644
--- a/src/ast/modules.cc
+++ b/src/ast/modules.cc
@@ -212,6 +212,13 @@ void ModuleDescriptor::MakeIndirectExportsExplicit(Zone* zone) {
}
}
+ModuleDescriptor::CellIndexKind ModuleDescriptor::cell_index_kind(
+ int cell_index) {
+ if (cell_index > 0) return kExport;
+ if (cell_index < 0) return kImport;
+ return kInvalid;
+}
+
void ModuleDescriptor::AssignCellIndices() {
int export_index = 1;
for (auto it = regular_exports_.begin(); it != regular_exports_.end();) {

Powered by Google App Engine
This is Rietveld 408576698