about summary refs log tree commit diff stats
path: root/src/utils/eprint.nim
diff options
context:
space:
mode:
Diffstat (limited to 'src/utils/eprint.nim')
-rw-r--r--src/utils/eprint.nim11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/utils/eprint.nim b/src/utils/eprint.nim
index 128d34d9..d13fcf91 100644
--- a/src/utils/eprint.nim
+++ b/src/utils/eprint.nim
@@ -10,6 +10,17 @@ template eprint*(s: varargs[string, `$`]) = {.cast(noSideEffect).}:
     stderr.write(x)
   stderr.write('\n')
 
+template eecho*(s: varargs[string, `$`]) = {.cast(noSideEffect).}:
+  var a = false
+  var o = ""
+  for x in s:
+    if not a:
+      a = true
+    else:
+      o &= ' '
+    o &= x
+  echo o
+
 template print*(s: varargs[string, `$`]) =
   for x in s:
     stdout.write(x)