Mercurial > projects > dil
diff trunk/src/dil/semantic/Pass1.d @ 692:d33895f679eb
Tidied up the class Scope a bit.
author | Aziz K?ksal <aziz.koeksal@gmail.com> |
---|---|
date | Tue, 22 Jan 2008 18:32:39 +0100 |
parents | eaf6444b6284 |
children | c67d2c3c0b3d |
line wrap: on
line diff
--- a/trunk/src/dil/semantic/Pass1.d Tue Jan 22 18:05:37 2008 +0100 +++ b/trunk/src/dil/semantic/Pass1.d Tue Jan 22 18:32:39 2008 +0100 @@ -57,9 +57,7 @@ { assert(modul.root !is null); // Create module scope. - scop = new Scope(); - scop.symbol = modul; // Set this module as the scope's symbol. - scop.infoMan = modul.infoMan; + scop = new Scope(null, modul); visit(modul.root); } @@ -298,7 +296,7 @@ D visit(VariablesDeclaration vd) { // Error if we are in an interface. - if (scop.isInterface) + if (scop.symbol.isInterface) return error(vd.begin, MSG.InterfaceCantHaveVariables), vd; // Insert variable symbols in this declaration into the symbol table.