From: Jérémie Astor Date: Tue, 16 Jun 2020 20:00:47 +0000 (+0200) Subject: :art: ADD_REF in env_add_type X-Git-Tag: nightly~1469 X-Git-Url: http://10.10.0.4:5575/?a=commitdiff_plain;h=a807c9b79cae2f34c7cd424624aa6e4ecabbbb57;p=gwion.git :art: ADD_REF in env_add_type --- diff --git a/src/env/env.c b/src/env/env.c index 305544c8..4d051660 100644 --- a/src/env/env.c +++ b/src/env/env.c @@ -80,6 +80,7 @@ ANN void env_pop(const Env env, const m_uint scope) { ANN void env_add_type(const Env env, const Type type) { const Type v_type = type_copy(env->gwion->mp, env->gwion->type[et_class]); + ADD_REF(v_type); v_type->e->d.base_type = type; SET_FLAG(type, builtin); const Symbol sym = insert_symbol(type->name);