summary refs log tree commit diff stats
path: root/compiler/transf.nim
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/transf.nim')
-rw-r--r--compiler/transf.nim6
1 files changed, 3 insertions, 3 deletions
diff --git a/compiler/transf.nim b/compiler/transf.nim
index f30f8583a..f7ec6c97f 100644
--- a/compiler/transf.nim
+++ b/compiler/transf.nim
@@ -979,7 +979,7 @@ proc transformBody*(module: PSym, n: PNode, prc: PSym): PNode =
     #result = liftLambdas(prc, result)
     when useEffectSystem: trackProc(prc, result)
     result = liftLocalsIfRequested(prc, result)
-    if c.needsDestroyPass and newDestructors:
+    if c.needsDestroyPass: #and newDestructors:
       result = injectDestructorCalls(prc, result)
     incl(result.flags, nfTransf)
       #if prc.name.s == "testbody":
@@ -996,7 +996,7 @@ proc transformStmt*(module: PSym, n: PNode): PNode =
     when useEffectSystem: trackTopLevelStmt(module, result)
     #if n.info ?? "temp.nim":
     #  echo renderTree(result, {renderIds})
-    if c.needsDestroyPass and newDestructors:
+    if c.needsDestroyPass:
       result = injectDestructorCalls(module, result)
     incl(result.flags, nfTransf)
 
@@ -1007,6 +1007,6 @@ proc transformExpr*(module: PSym, n: PNode): PNode =
     var c = openTransf(module, "")
     result = processTransf(c, n, module)
     liftDefer(c, result)
-    if c.needsDestroyPass and newDestructors:
+    if c.needsDestroyPass:
       result = injectDestructorCalls(module, result)
     incl(result.flags, nfTransf)