aboutsummaryrefslogtreecommitdiffstats
path: root/src/shared/cplusplus/Symbols.h
diff options
context:
space:
mode:
authorRoberto Raggi <roberto.raggi@nokia.com>2010-08-11 13:46:32 +0200
committerRoberto Raggi <roberto.raggi@nokia.com>2010-08-11 15:25:19 +0200
commitf74ba9daef50a0b267056c8753819d59621fc000 (patch)
treeb8400aa8bd8248b6b42552f79d56294ed04d8657 /src/shared/cplusplus/Symbols.h
parent6618a3cd679bf76f8325ca38b934545b0d8f4c60 (diff)
Introduced CPlusPlus::Template and process the template declarations.
Diffstat (limited to 'src/shared/cplusplus/Symbols.h')
-rw-r--r--src/shared/cplusplus/Symbols.h35
1 files changed, 35 insertions, 0 deletions
diff --git a/src/shared/cplusplus/Symbols.h b/src/shared/cplusplus/Symbols.h
index bc2b6b8330..b3f388f977 100644
--- a/src/shared/cplusplus/Symbols.h
+++ b/src/shared/cplusplus/Symbols.h
@@ -376,6 +376,41 @@ private:
};
};
+class CPLUSPLUS_EXPORT Template: public Scope, public Type
+{
+public:
+ Template(TranslationUnit *translationUnit, unsigned sourceLocation, const Name *name);
+ virtual ~Template();
+
+ unsigned templateParameterCount() const;
+ Symbol *templateParameterAt(unsigned index) const;
+ Symbol *declaration() const;
+
+ // Symbol's interface
+ virtual FullySpecifiedType type() const;
+
+ // Type's interface
+ virtual bool isEqualTo(const Type *other) const;
+
+ virtual const Template *asTemplate() const
+ { return this; }
+
+ virtual Template *asTemplate()
+ { return this; }
+
+ virtual const Template *asTemplateType() const
+ { return this; }
+
+ virtual Template *asTemplateType()
+ { return this; }
+
+protected:
+ virtual void visitSymbol0(SymbolVisitor *visitor);
+ virtual void accept0(TypeVisitor *visitor);
+ virtual bool matchType0(const Type *otherType, TypeMatcher *matcher) const;
+};
+
+
class CPLUSPLUS_EXPORT Namespace: public Scope, public Type
{
public: