diff sema/Scope.d @ 99:857f0d530789 new_gen

Imports and improved module statement Allow "module a.b.c" Supports most forms of D's import. import A, B; import A, B = C; import A, B : a = b, c;
author Anders Halager <halager@gmail.com>
date Tue, 06 May 2008 21:59:22 +0200
parents 621cedba53ea
children fea8d61a2451
line wrap: on
line diff
--- a/sema/Scope.d	Tue May 06 21:55:29 2008 +0200
+++ b/sema/Scope.d	Tue May 06 21:59:22 2008 +0200
@@ -3,6 +3,7 @@
 import tango.io.Stdout;
 
 import lexer.Token,
+       ast.Module,
        ast.Decl,
        ast.Exp;
 
@@ -16,16 +17,15 @@
     {
         this.enclosing = enclosing;
         this.func = enclosing.func;
+        this.inModule = enclosing.inModule;
     }
 
     Scope enclosing;
+    Module inModule;
 
     void add(Identifier id)
     {
-//        auto s = new Symbol;
-//        s.id = id;
         symbols[id] = id;
-//        return s;
     }
 
     Identifier find(Identifier id)