From fe900a34296d78cef855a21ebed62531c113e34e Mon Sep 17 00:00:00 2001 From: fennecdjay Date: Wed, 9 Oct 2019 22:34:44 +0200 Subject: [PATCH] :art: Remove useless check_td test --- src/parse/check.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/parse/check.c b/src/parse/check.c index e75ad4ce..516af527 100644 --- a/src/parse/check.c +++ b/src/parse/check.c @@ -97,9 +97,7 @@ ANN Type check_td(const Env env, Type_Decl *td) { CHECK_OO(check_exp(env, td->exp)) // TODO: check me const Type t = actual_type(env->gwion, td->exp->type); - if(!t || (is_class(env->gwion, td->exp->type) && t == env->gwion->type[et_class])) - ERR_O(td->exp->pos, _("Expression must be of type '%s', not '%s'\n" - "maybe you meant typeof(Expression)"), env->gwion->type[et_class]->name, td->exp->type->name); + assert(t); m_uint depth; td->xid = str2list(env, t->name, &depth, td->exp->pos); if(depth) { -- 2.43.0