From: fennecdjay Date: Mon, 12 Feb 2024 13:21:31 +0000 (+0100) Subject: :fire: poison scan1 (while) X-Git-Tag: nightly~94 X-Git-Url: http://10.10.0.4:5575/?a=commitdiff_plain;h=1000e3e7b070c31db012c05ce7c9edba9a7c32df;p=gwion.git :fire: poison scan1 (while) --- diff --git a/src/parse/scan1.c b/src/parse/scan1.c index 45261db0..42a7c9ce 100644 --- a/src/parse/scan1.c +++ b/src/parse/scan1.c @@ -104,12 +104,13 @@ static inline bool scan1_defined(const Env env, const Var_Decl *var) { ANN bool abstract_array(const Env env, const Array_Sub array) { Exp* e = array->exp; + bool ok = true; while(e) { if(!exp_is_zero(e)) - ERR_B(e->loc, _("arrays of abstract type should use `0` size")); + ERR_OK(ok, e->loc, _("arrays of abstract type should use `0` size")); e = e->next; } - return true; + return ok; } ANN static bool scan1_decl(const Env env, Exp_Decl *const decl) {