From 65ef1c1dc5a7d38787e350fe83f4b03619074e9d Mon Sep 17 00:00:00 2001 From: Thomas Leonard Date: Tue, 23 Sep 2008 10:55:19 +0100 Subject: [PATCH] Moved _externals module to dlt._externals --- dmd/module.c | 7 ++++--- dmd/statement.c | 3 ++- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/dmd/module.c b/dmd/module.c index 012e63d..b436a64 100644 --- a/dmd/module.c +++ b/dmd/module.c @@ -682,6 +682,9 @@ void Module::semantic() if (semanticstarted) return; + Array *dlt_package = new Array(); + dlt_package->push(Id::dlt); + //printf("+Module::semantic(this = %p, '%s'): parent = %p\n", this, toChars(), parent); semanticstarted = 1; @@ -704,7 +707,7 @@ void Module::semantic() return; members->push(mainFn); - Import *im = new Import(0, NULL, Id::_externals, NULL, true); + Import *im = new Import(0, dlt_package, Id::_externals, NULL, true); members->shift(im); break; @@ -719,8 +722,6 @@ void Module::semantic() /* If this is not dlt.core ... */ if (ident != Id::core || parent == NULL || parent->parent || parent->ident != Id::dlt) { - Array *dlt_package = new Array(); - dlt_package->push(Id::dlt); Import *im = new Import(0, dlt_package, Id::core, NULL, 0); members->shift(im); } diff --git a/dmd/statement.c b/dmd/statement.c index 70471cb..104649e 100644 --- a/dmd/statement.c +++ b/dmd/statement.c @@ -388,7 +388,8 @@ Statement *InjectorMainBody::semantic(Scope *sc) } // Externals externals = new _externals.Externals() - TypeIdentifier *extType = new TypeIdentifier(loc, Id::_externals); + TypeIdentifier *extType = new TypeIdentifier(loc, Id::dlt); + extType->addIdent(Id::_externals); extType->addIdent(Id::Externals); Expression *newExt = new NewExp(loc, NULL, NULL, extType, NULL); -- 2.11.4.GIT