implements overloadable enum values; WIP (#18470)

* implements overloadable enum values
* simpler code
This commit is contained in:
Andreas Rumpf 2021-07-28 12:46:28 +02:00 • committed by GitHub
commit a273ea70e8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 125 additions and 11 deletions

View file

@ -2197,7 +2197,7 @@ proc paramTypesMatch*(m: var TCandidate, f, a: PType,
var best = -1
for i in 0..<arg.len:
if arg[i].sym.kind in {skProc, skFunc, skMethod, skConverter,
skIterator, skMacro, skTemplate}:
skIterator, skMacro, skTemplate, skEnumField}:
copyCandidate(z, m)
z.callee = arg[i].typ
if tfUnresolved in z.callee.flags: continue