Commit 5365d081e023f097ec6caad03bd67884b34487e7

Thomas de Grivel 2024-03-26T11:00:07

better error message in env

diff --git a/.ic3_history b/.ic3_history
index e5bc7b3..389ecfc 100644
--- a/.ic3_history
+++ b/.ic3_history
@@ -1,9 +1,3 @@
-  2 + 2
-end
-def
-123 = 123
-def
-def a = 1
 def 1 = 1
 def a = 1
 def 1 = 1
@@ -97,3 +91,9 @@ dt
 double(3/4)
 1 / double(3/4)
 a = b
+a = 1
+b = a
+b = ^ a
+b = a
+a = ^ b
+a = ^ c
diff --git a/libc3/env.c b/libc3/env.c
index cac5305..62d99d0 100644
--- a/libc3/env.c
+++ b/libc3/env.c
@@ -270,9 +270,9 @@ bool env_eval_call_arguments (s_env *env, const s_list *args,
     *tail = list_new(NULL);
     if (! env_eval_tag(env, &args->tag, &(*tail)->tag)) {
       list_delete_all(tmp);
-      err_puts("env_eval_call_arguments: invalid argument: ");
+      err_write_1("env_eval_call_arguments: invalid argument: ");
       err_inspect(&args->tag);
-      err_puts("\n");
+      err_write_1("\n");
       return false;
     }
     tail = &(*tail)->next.data.list;