summary refs log tree commit diff stats
path: root/compiler/sempass2.nim
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2019-04-09 21:25:23 +0200
committerAraq <rumpf_a@web.de>2019-04-09 21:25:36 +0200
commit72408842d9ca79e9b64691bb8fa906a3e1014a43 (patch)
treee94e39b5ecb66f9c26fec3634a46f84e22b34808 /compiler/sempass2.nim
parenta4883b84260eb050b9e7756d48a22f7b6ead08f5 (diff)
downloadNim-72408842d9ca79e9b64691bb8fa906a3e1014a43.tar.gz
koch.nim compiles with --newruntime
Diffstat (limited to 'compiler/sempass2.nim')
-rw-r--r--compiler/sempass2.nim4
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/sempass2.nim b/compiler/sempass2.nim
index 03fd34c86..67de3217a 100644
--- a/compiler/sempass2.nim
+++ b/compiler/sempass2.nim
@@ -707,9 +707,9 @@ proc track(tracked: PEffects, n: PNode) =
     let op = a.typ
     if getConstExpr(tracked.ownerModule, n, tracked.graph) != nil:
       return
-    if op != nil:
+    if n.typ != nil:
       if tracked.owner.kind != skMacro:
-        createTypeBoundOps(tracked.c, op, n.info)
+        createTypeBoundOps(tracked.c, n.typ, n.info)
     if a.kind == nkCast and a[1].typ.kind == tyProc:
       a = a[1]
     # XXX: in rare situations, templates and macros will reach here after