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

Unified Diff: src/ast/modules.cc

Issue 2368613002: [modules] Simplify treatment of empty imports. (Closed)
Patch Set: Created 4 years, 3 months 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
« no previous file with comments | « src/ast/modules.h ('k') | src/ast/scopeinfo.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ast/modules.cc
diff --git a/src/ast/modules.cc b/src/ast/modules.cc
index 6a0f26a89580752df51f2d4aaefe2fea8cda40a1..2d28d5564b546b01ea1b2ab5bd3eb56b6572b379 100644
--- a/src/ast/modules.cc
+++ b/src/ast/modules.cc
@@ -23,19 +23,14 @@ void ModuleDescriptor::AddImport(
void ModuleDescriptor::AddStarImport(
const AstRawString* local_name, const AstRawString* module_request,
Scanner::Location loc, Zone* zone) {
- DCHECK_NOT_NULL(local_name);
Entry* entry = new (zone) Entry(loc);
entry->local_name = local_name;
entry->module_request = AddModuleRequest(module_request);
- AddSpecialImport(entry, zone);
+ AddNamespaceImport(entry, zone);
}
-
-void ModuleDescriptor::AddEmptyImport(
- const AstRawString* module_request, Scanner::Location loc, Zone* zone) {
- Entry* entry = new (zone) Entry(loc);
- entry->module_request = AddModuleRequest(module_request);
- AddSpecialImport(entry, zone);
+void ModuleDescriptor::AddEmptyImport(const AstRawString* module_request) {
+ AddModuleRequest(module_request);
}
« no previous file with comments | « src/ast/modules.h ('k') | src/ast/scopeinfo.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698