Also reset the context env when updating interaction-environment.

Fixes issue #200.
This commit is contained in:
Alex Shinn 2013-10-10 16:31:28 +09:00
parent 3995c4505f
commit 363d2bda24

1
main.c
View file

@ -202,6 +202,7 @@ static sexp sexp_load_standard_params (sexp ctx, sexp e) {
#endif #endif
res = sexp_make_env(ctx); res = sexp_make_env(ctx);
sexp_env_parent(res) = e; sexp_env_parent(res) = e;
sexp_context_env(ctx) = res;
sexp_set_parameter(ctx, sexp_global(ctx, SEXP_G_META_ENV), sexp_global(ctx, SEXP_G_INTERACTION_ENV_SYMBOL), res); sexp_set_parameter(ctx, sexp_global(ctx, SEXP_G_META_ENV), sexp_global(ctx, SEXP_G_INTERACTION_ENV_SYMBOL), res);
sexp_gc_release3(ctx); sexp_gc_release3(ctx);
return res; return res;