diff options
author | Andreas Rumpf <rumpf_a@web.de> | 2017-09-26 23:07:37 +0200 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2017-09-26 23:07:37 +0200 |
commit | 414e7eff0450d45de9c91f724c021d987b08c693 (patch) | |
tree | 0ece5508ad6296df0165eba8cc11baaac24d2b34 /lib/js | |
parent | 2bdbe97af1cd9046ba8028c5530e75025561afcc (diff) | |
download | Nim-414e7eff0450d45de9c91f724c021d987b08c693.tar.gz |
make tests green again
Diffstat (limited to 'lib/js')
-rw-r--r-- | lib/js/jsffi.nim | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/js/jsffi.nim b/lib/js/jsffi.nim index 0d359d9e6..13eb1e759 100644 --- a/lib/js/jsffi.nim +++ b/lib/js/jsffi.nim @@ -300,7 +300,7 @@ macro `.()`*[K: string | cstring, V: proc](obj: JsAssoc[K, V], result = quote do: (`dotOp`(`obj`, `field`))() for elem in args: - result[0].add elem + result.add elem # Iterators: @@ -471,7 +471,7 @@ macro bindMethod*(procedure: typed): auto = # construct the `this` parameter: thisQuote = quote do: var `this` {. nodecl, importc .} : `thisType` - call = newNimNode(nnkCall).add(rawProc[0], thisQuote[0][0][0][0]) + call = newNimNode(nnkCall).add(rawProc[0], thisQuote[0][0][0]) # construct the procedure call inside the method if args.len > 2: for idx in 2..args.len-1: @@ -483,6 +483,6 @@ macro bindMethod*(procedure: typed): auto = params, rawProc[4], rawProc[5], - newTree(nnkStmtList, thisQuote[0], call) + newTree(nnkStmtList, thisQuote, call) ) result = body |