From aa6a0b6a6553e854be6731e8ebd4306605b00e6e Mon Sep 17 00:00:00 2001 From: David Robillard Date: Sun, 26 Dec 2010 20:07:18 +0000 Subject: Remove AType::PRIM. git-svn-id: http://svn.drobilla.net/resp/resp@357 ad02d1e2-f140-0410-9f75-f8b11f17cedd --- src/resp.hpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src/resp.hpp') diff --git a/src/resp.hpp b/src/resp.hpp index bde4bcf..8fa4b9b 100644 --- a/src/resp.hpp +++ b/src/resp.hpp @@ -353,7 +353,7 @@ list_contains(const ATuple* head, const AST* child) { /// Type Expression, e.g. "Int", "(Fn (Int Int) Float)" struct AType : public ATuple { - enum Kind { VAR, NAME, PRIM, EXPR, DOTS }; + enum Kind { VAR, NAME, EXPR, DOTS }; AType(const ASymbol* s, Kind k) : ATuple(s, NULL, s->loc), kind(k), id(0) { tag(T_TYPE); } AType(Cursor c, unsigned i) : ATuple(c), kind(VAR), id(i) { tag(T_TYPE); } AType(Cursor c, Kind k=EXPR) : ATuple(c), kind(k), id(0) { tag(T_TYPE); } @@ -453,7 +453,6 @@ AST::operator==(const AST& rhs) const switch (me->kind) { case AType::VAR: return me->id == rt->id; case AType::NAME: return me->head()->str() == rt->head()->str(); - case AType::PRIM: return me->head()->str() == rt->head()->str(); case AType::EXPR: return list_equals(me, rt); case AType::DOTS: return true; } @@ -640,9 +639,9 @@ struct TEnv : public Env { , varID(1) , Closure(new AType(penv.sym("Closure"), AType::NAME)) , Dots(new AType(Cursor(), AType::DOTS)) - , Fn(new AType(penv.sym("Fn"), AType::PRIM)) + , Fn(new AType(penv.sym("Fn"), AType::NAME)) , Tup(new AType(penv.sym("Tup"), AType::NAME)) - , U(new AType(penv.sym("U"), AType::PRIM)) + , U(new AType(penv.sym("U"), AType::NAME)) { Object::pool.addRoot(Fn); } -- cgit v1.2.1