changeset 265:3a2a0a63c638

- Changed some string types to Token*.
author aziz
date Fri, 03 Aug 2007 18:05:01 +0000
parents 50cc74026ea8
children fea4e8b6cea5
files trunk/src/Declarations.d trunk/src/Parser.d
diffstat 2 files changed, 7 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/trunk/src/Declarations.d	Fri Aug 03 17:51:02 2007 +0000
+++ b/trunk/src/Declarations.d	Fri Aug 03 18:05:01 2007 +0000
@@ -308,10 +308,10 @@
 
 class TemplateDeclaration : Declaration
 {
-  string templateName;
+  Token* templateName;
   TemplateParameters templateParams;
   Declaration[] decls;
-  this(string templateName, TemplateParameters templateParams, Declaration[] decls)
+  this(Token* templateName, TemplateParameters templateParams, Declaration[] decls)
   {
     super(true);
     this.templateName = templateName;
--- a/trunk/src/Parser.d	Fri Aug 03 17:51:02 2007 +0000
+++ b/trunk/src/Parser.d	Fri Aug 03 18:05:01 2007 +0000
@@ -546,8 +546,8 @@
         if (token.type == T.LParen)
         {
           nT();
-          auto ident = requireIdentifier();
-          switch (ident)
+          auto ident = requireId();
+          switch (ident ? ident.identifier : null)
           {
           case "C":
             if (token.type == T.PlusPlus)
@@ -1250,7 +1250,7 @@
   {
     assert(token.type == T.Template);
     nT(); // Skip template keyword.
-    auto templateName = requireIdentifier();
+    auto templateName = requireId();
     auto templateParams = parseTemplateParameterList();
     auto decls = parseDeclarationDefinitionsBlock();
     return new TemplateDeclaration(templateName, templateParams, decls);
@@ -1757,8 +1757,8 @@
         if (token.type == T.LParen)
         {
           nT();
-          auto ident = requireIdentifier();
-          switch (ident)
+          auto ident = requireId();
+          switch (ident ? ident.identifier : null)
           {
           case "C":
             if (token.type == T.PlusPlus)