From: Jérémie Astor Date: Mon, 9 Aug 2021 14:27:31 +0000 (+0200) Subject: :art: Fix typedef stuff X-Git-Tag: nightly~471 X-Git-Url: http://10.10.0.4:5575/?a=commitdiff_plain;h=6645156288a66b9e5fbd5122a8a275025b16e09b;p=gwion.git :art: Fix typedef stuff --- diff --git a/src/import/import_cdef.c b/src/import/import_cdef.c index 734cd180..06a93731 100644 --- a/src/import/import_cdef.c +++ b/src/import/import_cdef.c @@ -92,7 +92,6 @@ Type gwi_class_ini(const Gwi gwi, const m_str name, const m_str parent) { t->info->cdef->base.type = t; t->info->tuple = new_tupleform(gwi->gwion->mp, p); t->info->parent = p; - if (td->array) set_tflag(t, tflag_typedef); if (ck.sl) set_tflag(t, tflag_tmpl | tflag_ntmpl); else diff --git a/src/parse/scan0.c b/src/parse/scan0.c index 7cdfa37d..1fd0d5e3 100644 --- a/src/parse/scan0.c +++ b/src/parse/scan0.c @@ -283,9 +283,8 @@ ANN static m_bool scan0_class_def_pre(const Env env, const Class_Def cdef) { return GW_OK; } -ANN static void cdef_flag(const Class_Def cdef, const Type t) { +ANN static inline void cdef_flag(const Class_Def cdef, const Type t) { if (cdef->base.tmpl) set_tflag(t, tflag_tmpl); - if (cdef->base.ext && cdef->base.ext->array) set_tflag(t, tflag_typedef); } ANN static Type get_parent_base(const Env env, Type_Decl *td) { @@ -345,7 +344,6 @@ ANN static Type scan0_class_def_init(const Env env, const Class_Def cdef) { t->flag |= cdef->flag; // add_type(env, t->info->value->from->owner, t); cdef_flag(cdef, t); - if (cdef->base.ext && cdef->base.ext->array) set_tflag(t, tflag_typedef); return t; }