next steps for first class iterators
This commit is contained in:
parent
538699a281
commit
dd9ad9e497
7 changed files with 16 additions and 7 deletions
|
|
@ -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:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue