summaryrefslogtreecommitdiff
path: root/src/hir/type.hpp
diff options
context:
space:
mode:
authorJohn Hodge <tpg@mutabah.net>2016-06-09 23:43:36 +0800
committerJohn Hodge <tpg@mutabah.net>2016-06-09 23:43:36 +0800
commit2dfe4182cbd34a775b7bea479d54b789019c0204 (patch)
tree680d004459d45ba47c0b0b8e7371a3e1cd4ba4be /src/hir/type.hpp
parent9fdde2fa1eff318c310efaf92172e4c928ed84c7 (diff)
downloadmrust-2dfe4182cbd34a775b7bea479d54b789019c0204.tar.gz
HIR - Add closure type
Diffstat (limited to 'src/hir/type.hpp')
-rw-r--r--src/hir/type.hpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/hir/type.hpp b/src/hir/type.hpp
index b3dd0fc8..8c3e1919 100644
--- a/src/hir/type.hpp
+++ b/src/hir/type.hpp
@@ -14,6 +14,7 @@ class Struct;
class Enum;
class TypeRef;
+class ExprNode_Closure;
enum class InferClass
{
@@ -113,7 +114,12 @@ public:
::HIR::BorrowType type;
::std::unique_ptr<TypeRef> inner;
}),
- (Function, FunctionType)
+ (Function, FunctionType),
+ (Closure, struct {
+ const ::HIR::ExprNode_Closure* node;
+ ::std::unique_ptr<TypeRef> m_rettype;
+ ::std::vector<TypeRef> m_arg_types;
+ })
);
Data m_data;