diff trunk/src/dil/Declarations.d @ 563:c838ed7f2ac9

Added 'override' to some methods.
author Aziz K?ksal <aziz.koeksal@gmail.com>
date Fri, 28 Dec 2007 20:11:58 +0100
parents b0533550d64c
children 3c867a683258
line wrap: on
line diff
--- a/trunk/src/dil/Declarations.d	Fri Dec 28 17:48:47 2007 +0100
+++ b/trunk/src/dil/Declarations.d	Fri Dec 28 20:11:58 2007 +0100
@@ -30,9 +30,9 @@
 
   void semantic(Scope sc)
   {
-//     foreach (node; this.children)
-//       if (node.category == NodeCategory.Declaration)
-//         (cast(Declaration)cast(void*)node).semantic(sc);
+    foreach (node; this.children)
+      if (node.category == NodeCategory.Declaration)
+        (cast(Declaration)cast(void*)node).semantic(sc);
   }
 
   final bool isStatic()
@@ -75,7 +75,7 @@
     addChildren(ds.children);
   }
 
-  void semantic(Scope scop)
+  override void semantic(Scope scop)
   {
     foreach (node; this.children)
     {
@@ -85,6 +85,7 @@
   }
 }
 
+/// Single semicolon.
 class EmptyDeclaration : Declaration
 {
   this()
@@ -92,14 +93,14 @@
     mixin(set_kind);
   }
 
-  void semantic(Scope)
+  override void semantic(Scope)
   {}
 }
 
 /++
   Illegal declarations encompass all tokens that don't
   start a DeclarationDefinition.
-  See_Also: dil.Parser.isDeclDefStartToken()
+  See_Also: dil.Token.isDeclDefStartToken()
 +/
 class IllegalDeclaration : Declaration
 {
@@ -108,7 +109,7 @@
     mixin(set_kind);
   }
 
-  void semantic(Scope)
+  override void semantic(Scope)
   {}
 }
 
@@ -443,7 +444,7 @@
 
   Variable[] variables;
 
-  void semantic(Scope scop)
+  override void semantic(Scope scop)
   {
     Type type;
 
@@ -693,7 +694,7 @@
     this.args = args;
   }
 
-  void semantic(Scope scop)
+  override void semantic(Scope scop)
   {
     pragmaSemantic(scop, begin, ident, args);
     decls.semantic(scop);