summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rwxr-xr-xcompiler/options.nim1
-rw-r--r--compiler/sempass2.nim3
-rwxr-xr-xcompiler/transf.nim2
3 files changed, 3 insertions, 3 deletions
diff --git a/compiler/options.nim b/compiler/options.nim
index 316ec2b14..f5e54a613 100755
--- a/compiler/options.nim
+++ b/compiler/options.nim
@@ -12,6 +12,7 @@ import
   
 const
   hasTinyCBackend* = defined(tinyc)
+  useEffectSystem* = false
 
 type                          # please make sure we have under 32 options
                               # (improves code efficiency a lot!)
diff --git a/compiler/sempass2.nim b/compiler/sempass2.nim
index ccf385876..936fe1822 100644
--- a/compiler/sempass2.nim
+++ b/compiler/sempass2.nim
@@ -219,8 +219,7 @@ proc checkRaisesSpec(spec, real: PNode) =
   for r in items(real):
     block search:
       for s in 0 .. <spec.len:
-        # s supertype of r?
-        if inheritanceDiff(spec[s].typ, r.excType) <= 0:
+        if inheritanceDiff(r.excType, spec[s].typ) <= 0:
           used.incl(s)
           break search
       # XXX call graph analysis would be nice here!
diff --git a/compiler/transf.nim b/compiler/transf.nim
index a99041046..767a23111 100755
--- a/compiler/transf.nim
+++ b/compiler/transf.nim
@@ -691,7 +691,7 @@ proc transformBody*(module: PSym, n: PNode, prc: PSym): PNode =
   if nfTransf in n.flags or prc.kind in {skTemplate, skMacro}:
     result = n
   else:
-    when false: trackProc(prc, n)
+    when useEffectSystem: trackProc(prc, n)
     var c = openTransf(module, "")
     result = processTransf(c, n)
     if prc.kind != skMacro: