From: Jérémie Astor Date: Mon, 4 May 2020 22:17:09 +0000 (+0200) Subject: :bug: Fix push_global X-Git-Tag: nightly~1681 X-Git-Url: http://10.10.0.4:5575/?a=commitdiff_plain;h=3a186d6668349e5a2efb93ca56be13b65020b6f9;p=gwion.git :bug: Fix push_global --- diff --git a/src/gwion.c b/src/gwion.c index b8a73e6c..97d42f06 100644 --- a/src/gwion.c +++ b/src/gwion.c @@ -178,7 +178,7 @@ ANN struct SpecialId_* specialid_get(const Gwion gwion, const Symbol sym) { ANN void push_global(struct Gwion_ *gwion, const m_str name) { const Nspc nspc = new_nspc(gwion->mp, name); nspc->parent = gwion->env->global_nspc; - gwion->env->global_nspc = nspc; + gwion->env->curr = gwion->env->global_nspc = nspc; } ANN Nspc pop_global(struct Gwion_ *gwion) { diff --git a/src/import/checker.c b/src/import/checker.c index 1da445e3..03a6c524 100644 --- a/src/import/checker.c +++ b/src/import/checker.c @@ -35,6 +35,7 @@ ANN static m_bool ac_run(const Gwi gwi, struct AC *ac); ANN static Array_Sub mk_array(MemPool mp, struct AC *ac) { const Array_Sub array = new_array_sub(mp, ac->base); array->depth = ac->depth; + array->exp = ac->base; return array; }