summary refs log tree commit diff stats
path: root/compiler/sigmatch.nim
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2012-11-26 02:43:32 +0100
committerAraq <rumpf_a@web.de>2012-11-26 02:43:32 +0100
commitdd9ad9e49730cec954e9113f0136053c5020aafd (patch)
tree09cce2a19da1d7688a021b3c5fd6e603656c599b /compiler/sigmatch.nim
parent538699a2810017981b4cb8b6994c0da0afeb0452 (diff)
downloadNim-dd9ad9e49730cec954e9113f0136053c5020aafd.tar.gz
next steps for first class iterators
Diffstat (limited to 'compiler/sigmatch.nim')
-rwxr-xr-xcompiler/sigmatch.nim2
1 files changed, 2 insertions, 0 deletions
diff --git a/compiler/sigmatch.nim b/compiler/sigmatch.nim
index 03fb9a075..799622355 100755
--- a/compiler/sigmatch.nim
+++ b/compiler/sigmatch.nim
@@ -293,6 +293,8 @@ proc procTypeRel(c: var TCandidate, f, a: PType): TTypeRelation =
     elif tfThread in f.flags and a.flags * {tfThread, tfNoSideEffect} == {}:
       # noSideEffect implies ``tfThread``! XXX really?
       return isNone
+    elif f.flags * {tfIterator} != a.flags * {tfIterator}:
+      return isNone
     elif f.callconv != a.callconv:
       # valid to pass a 'nimcall' thingie to 'closure':
       if f.callconv == ccClosure and a.callconv == ccDefault: