summaryrefslogtreecommitdiff
path: root/src/shared/cplusplus
diff options
context:
space:
mode:
authorRoberto Raggi <roberto.raggi@nokia.com>2009-12-08 12:04:57 +0100
committerRoberto Raggi <roberto.raggi@nokia.com>2009-12-08 12:20:14 +0100
commitfef2ad6bba36158de74127c3443aba70934cbca9 (patch)
tree394607141948d387df7f681f33e7255ae711adc0 /src/shared/cplusplus
parentf7164ae9d4936715cdefc379b73f263a0bf9e712 (diff)
downloadqt-creator-fef2ad6bba36158de74127c3443aba70934cbca9.tar.gz
Create TypenameArgument symbols.
Diffstat (limited to 'src/shared/cplusplus')
-rw-r--r--src/shared/cplusplus/AST.h4
-rw-r--r--src/shared/cplusplus/CheckDeclaration.cpp8
2 files changed, 8 insertions, 4 deletions
diff --git a/src/shared/cplusplus/AST.h b/src/shared/cplusplus/AST.h
index 47342c2e04..f21d9042fd 100644
--- a/src/shared/cplusplus/AST.h
+++ b/src/shared/cplusplus/AST.h
@@ -2083,7 +2083,7 @@ public:
ExpressionAST *type_id;
public: // annotations
- Argument *symbol;
+ TypenameArgument *symbol;
public:
virtual TypenameTypeParameterAST *asTypenameTypeParameter() { return this; }
@@ -2109,7 +2109,7 @@ public:
ExpressionAST *type_id;
public:
- Argument *symbol;
+ TypenameArgument *symbol;
public:
virtual TemplateTypeParameterAST *asTemplateTypeParameter() { return this; }
diff --git a/src/shared/cplusplus/CheckDeclaration.cpp b/src/shared/cplusplus/CheckDeclaration.cpp
index 3349263e1e..719a0c82eb 100644
--- a/src/shared/cplusplus/CheckDeclaration.cpp
+++ b/src/shared/cplusplus/CheckDeclaration.cpp
@@ -459,7 +459,9 @@ bool CheckDeclaration::visit(TypenameTypeParameterAST *ast)
sourceLocation = ast->name->firstToken();
const Name *name = semantic()->check(ast->name, _scope);
- Argument *arg = control()->newArgument(sourceLocation, name); // ### new template type
+ TypenameArgument *arg = control()->newTypenameArgument(sourceLocation, name);
+ FullySpecifiedType ty = semantic()->check(ast->type_id, _scope);
+ arg->setType(ty);
ast->symbol = arg;
_scope->enterSymbol(arg);
return false;
@@ -472,7 +474,9 @@ bool CheckDeclaration::visit(TemplateTypeParameterAST *ast)
sourceLocation = ast->name->firstToken();
const Name *name = semantic()->check(ast->name, _scope);
- Argument *arg = control()->newArgument(sourceLocation, name); // ### new template type
+ TypenameArgument *arg = control()->newTypenameArgument(sourceLocation, name);
+ FullySpecifiedType ty = semantic()->check(ast->type_id, _scope);
+ arg->setType(ty);
ast->symbol = arg;
_scope->enterSymbol(arg);
return false;