From: Jérémie Astor Date: Thu, 29 Apr 2021 16:04:16 +0000 (+0200) Subject: :bug: More on effects X-Git-Tag: nightly~706 X-Git-Url: http://10.10.0.4:5575/?a=commitdiff_plain;h=17e4aede3465ccda89d935a186d5c401be1af157;p=gwion.git :bug: More on effects --- diff --git a/src/parse/check.c b/src/parse/check.c index 00201261..a82abd75 100644 --- a/src/parse/check.c +++ b/src/parse/check.c @@ -1135,7 +1135,7 @@ ANN static m_bool check_stmt_return(const Env env, const Stmt_Exp stmt) { if(isa(ret_type, env->func->def->base->ret_type) > 0) return GW_OK; if(tflag(ret_type, tflag_noret)) - ERR_B(stmt->val->pos, _("Can't use type `{+G}%s{+G}` for return")); + ERR_B(stmt->val->pos, _("Can't use type `{+G}%s{+G}` for return"), ret_type->name); if(stmt->val) { if(env->func->def->base->xid == insert_symbol("@implicit") && ret_type == env->func->def->base->args->type) ERR_B(stmt_self(stmt)->pos, _("can't use implicit casting while defining it"))