]> Nishi Git Mirror - gwion.git/commitdiff
Revert ":art: Remove arg flag"
authorfennecdjay <astor.jeremie@wanadoo.fr>
Wed, 25 Sep 2019 21:33:29 +0000 (23:33 +0200)
committerfennecdjay <astor.jeremie@wanadoo.fr>
Wed, 25 Sep 2019 21:33:29 +0000 (23:33 +0200)
This reverts commit 82f00b7b4a517c723b3d0bf842d216a6f74ecb9c.

src/parse/check.c
src/parse/scan2.c
util

index 9f7f3dc07d6811982ee0257c2c9906c9017d58d0..1905510c350494e8bb7232cab14c1ea49784b33d 100644 (file)
@@ -212,7 +212,7 @@ ANN static Value check_non_res_value(const Env env, const Exp_Primary* primary)
     }
     return v;
   } else if(env->func && GET_FLAG(env->func->def, global)) {
-    if(!SAFE_FLAG(value, abstract) && value->owner)
+    if(!SAFE_FLAG(value, abstract) && !SAFE_FLAG(value, arg))
       ERR_O(exp_self(primary)->pos,
             _("non-global variable '%s' used from global function."), s_name(primary->d.var))
   }
index 8bc91b5f07c77755679f6b4f8e39b6bcc08632cd..f239b9cdccbf7e14d0e90237c16c5459da04d728 100644 (file)
@@ -48,7 +48,7 @@ ANN static Value arg_value(MemPool p, const Arg_List list) {
   if(!var->value) {
     const Value v = new_value(p, list->type, var->xid ? s_name(var->xid) : (m_str)__func__);
     if(list->td)
-      v->flag = list->td->flag;
+      v->flag = list->td->flag | ae_flag_arg;
     return v;
   }
   var->value->type = list->type;
diff --git a/util b/util
index 719eafbff96155bb5018cc599023efd72265edfe..3d2be8fdf552bdded221ddb266d55043c288da4a 160000 (submodule)
--- a/util
+++ b/util
@@ -1 +1 @@
-Subproject commit 719eafbff96155bb5018cc599023efd72265edfe
+Subproject commit 3d2be8fdf552bdded221ddb266d55043c288da4a