about summary refs log tree commit diff stats
path: root/src/display/client.nim
diff options
context:
space:
mode:
authorbptato <nincsnevem662@gmail.com>2023-09-09 19:32:41 +0200
committerbptato <nincsnevem662@gmail.com>2023-09-09 19:32:41 +0200
commitef43cb35d55370690f674b2234124c73cfdc9f15 (patch)
treeeb4cffb7719f1f444c71a81115c574893c901b1b /src/display/client.nim
parentea70a93aa1791cf57e5793a32662de0152b56008 (diff)
downloadchawan-ef43cb35d55370690f674b2234124c73cfdc9f15.tar.gz
fix compilation on 1.6.14
changing addr semantics strikes again
Diffstat (limited to 'src/display/client.nim')
-rw-r--r--src/display/client.nim6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/display/client.nim b/src/display/client.nim
index c621580a..302cdd4a 100644
--- a/src/display/client.nim
+++ b/src/display/client.nim
@@ -196,11 +196,11 @@ proc evalAction(client: Client, action: string, arg0: int32) =
   let ret = client.evalJS(action, "<command>")
   let ctx = client.jsctx
   if JS_IsFunction(ctx, ret):
-    if arg0 != 0: # no precnum
-      let arg0 = toJS(ctx, arg0)
+    if arg0 != 0:
+      var arg0 = toJS(ctx, arg0)
       JS_FreeValue(ctx, JS_Call(ctx, ret, JS_UNDEFINED, 1, addr arg0))
       JS_FreeValue(ctx, arg0)
-    else:
+    else: # no precnum
       JS_FreeValue(ctx, JS_Call(ctx, ret, JS_UNDEFINED, 0, nil))
   JS_FreeValue(ctx, ret)