From 3c48924f1330d51163a3d01b693f62bf00176fc5 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=A9mie=20Astor?= Date: Tue, 16 Nov 2021 20:59:17 +0100 Subject: [PATCH] :art: make loop idx value constant --- src/parse/check.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/parse/check.c b/src/parse/check.c index b572a14e..03e05fa3 100644 --- a/src/parse/check.c +++ b/src/parse/check.c @@ -1167,6 +1167,7 @@ ANN static void check_idx(const Env env, const Type base, struct EachIdx_ *const idx->v = new_value(env->gwion->mp, base, s_name(idx->sym)); valuefrom(env, idx->v->from, idx->pos); valid_value(env, idx->sym, idx->v); + SET_FLAG(idx->v, const); } /** sets for the key expression value -- 2.43.0