suggest: improvements

This commit is contained in:
Araq 2011-02-23 00:15:36 +01:00
commit 82514c9c1c
4 changed files with 70 additions and 39 deletions

View file

@ -564,7 +564,7 @@ proc IndexTypesMatch*(c: PContext, f, a: PType, arg: PNode): PNode =
proc argtypeMatches*(c: PContext, f, a: PType): bool =
var m: TCandidate
initCandidate(m, f)
result = paramTypesMatch(c, m, f, a, nil) != nil
result = paramTypesMatch(c, m, f, a, ast.emptyNode) != nil
proc setSon(father: PNode, at: int, son: PNode) =
if sonsLen(father) <= at: setlen(father.sons, at + 1)