From: fennecdjay Date: Sat, 12 Oct 2019 01:35:46 +0000 (+0200) Subject: :art: Improve specialid X-Git-Tag: nightly~2159^2~8 X-Git-Url: http://10.10.0.4:5575/?a=commitdiff_plain;h=1ad9da4b8721e4e5815aeeea74e51a811dc1ce0f;p=gwion.git :art: Improve specialid --- diff --git a/src/lib/import.c b/src/lib/import.c index c9d4a3a8..dd2d6a37 100644 --- a/src/lib/import.c +++ b/src/lib/import.c @@ -666,11 +666,7 @@ ANN void gwi_reserve(const Gwi gwi, const m_str str) { ANN void gwi_specialid(const Gwi gwi, const m_str id, const SpecialId spid) { struct SpecialId_ *a = mp_calloc(gwi->gwion->mp, SpecialId); - a->type = spid->type; - a->ck = spid->ck; - a->exec = spid->exec; - a->em = spid->em; - a->is_const = spid->is_const; + memcpy(a, spid, sizeof(struct SpecialId_)); map_set(&gwi->gwion->data->id, (vtype)insert_symbol(gwi->gwion->st, id), (vtype)a); gwi_reserve(gwi, id); }