# HG changeset patch # User Aziz K?ksal # Date 1200009293 -3600 # Node ID f15b054bb27e1115f069af2f12d303059ee8baf8 # Parent 933cd8d244679c6436d42c9269f62f1815163a51 Renamed Scope.push/pop to Scope.enter/exit. diff -r 933cd8d24467 -r f15b054bb27e trunk/src/dil/ast/Declarations.d --- a/trunk/src/dil/ast/Declarations.d Fri Jan 11 00:49:05 2008 +0100 +++ b/trunk/src/dil/ast/Declarations.d Fri Jan 11 00:54:53 2008 +0100 @@ -356,10 +356,10 @@ // Insert into current scope. scop.insert(symbol, name); // Create a new scope. - scop = scop.push(symbol); + scop = scop.enter(symbol); // Continue semantic analysis. decls && decls.semantic(scop); - scop.pop(); + scop.exit(); } } @@ -389,10 +389,10 @@ // Insert into current scope. scop.insert(symbol, name); // Create a new scope. - scop = scop.push(symbol); + scop = scop.enter(symbol); // Continue semantic analysis. decls && decls.semantic(scop); - scop.pop(); + scop.exit(); } } @@ -422,10 +422,10 @@ // Insert into current scope. scop.insert(symbol, name); // Create a new scope. - scop = scop.push(symbol); + scop = scop.enter(symbol); // Continue semantic analysis. decls && decls.semantic(scop); - scop.pop(); + scop.exit(); } } @@ -449,10 +449,10 @@ // Insert into current scope. scop.insert(symbol, name); // Create a new scope. - scop = scop.push(symbol); + scop = scop.enter(symbol); // Continue semantic analysis. decls && decls.semantic(scop); - scop.pop(); + scop.exit(); } } diff -r 933cd8d24467 -r f15b054bb27e trunk/src/dil/semantic/Scope.d --- a/trunk/src/dil/semantic/Scope.d Fri Jan 11 00:49:05 2008 +0100 +++ b/trunk/src/dil/semantic/Scope.d Fri Jan 11 00:54:53 2008 +0100 @@ -64,9 +64,9 @@ } /++ - Create a new inner scope. + Create and enter a new inner scope. +/ - Scope push(ScopeSymbol symbol) + Scope enter(ScopeSymbol symbol) { auto sc = new Scope(); sc.parent = this; @@ -78,7 +78,7 @@ /++ Destroy this scope and return the outer scope. +/ - Scope pop() + Scope exit() { auto sc = parent; // delete this;