summaryrefslogtreecommitdiff
path: root/tiger-compiler/src/ast/type-constructor.hh
diff options
context:
space:
mode:
Diffstat (limited to 'tiger-compiler/src/ast/type-constructor.hh')
-rw-r--r--tiger-compiler/src/ast/type-constructor.hh38
1 files changed, 38 insertions, 0 deletions
diff --git a/tiger-compiler/src/ast/type-constructor.hh b/tiger-compiler/src/ast/type-constructor.hh
new file mode 100644
index 0000000..87f57d8
--- /dev/null
+++ b/tiger-compiler/src/ast/type-constructor.hh
@@ -0,0 +1,38 @@
+/**
+ ** \file ast/type-constructor.hh
+ ** \brief Declaration of ast::TypeConstructor.
+ */
+
+#pragma once
+
+#include <ast/fwd.hh>
+#include <type/fwd.hh>
+
+namespace ast
+{
+ /** \class ast::TypeConstructor
+ ** \brief Create a new type.
+ */
+
+ class TypeConstructor
+ {
+ // FIXME DONE: Some code was deleted here.
+ public:
+ // Basic default constructor
+ // BUT we have a custom destructor this time (daring today aren't we?)
+ TypeConstructor();
+ ~TypeConstructor();
+
+ // Basic accessors
+ void created_type_set(const type::Type*);
+ const type::Type* created_type_get() const;
+
+ // Implementing the visitor so this can also be visited
+ void accept(ConstVisitor& v) const;
+ void accept(Visitor& v);
+
+ private:
+ const type::Type* reference_;
+ };
+} // namespace ast
+#include <ast/type-constructor.hxx>