make tsigbreak.nim compile
This commit is contained in:
parent
34143ee122
commit
e169eaac5b
5 changed files with 42 additions and 7 deletions
|
|
@ -122,7 +122,6 @@ type
|
|||
ConsiderFlag* = enum
|
||||
CoProc
|
||||
CoType
|
||||
CoNoGeneric
|
||||
|
||||
proc hashType(c: var MD5Context, t: PType; flags: set[ConsiderFlag]) =
|
||||
if t == nil:
|
||||
|
|
@ -153,10 +152,10 @@ proc hashType(c: var MD5Context, t: PType; flags: set[ConsiderFlag]) =
|
|||
if t.sym != nil and {sfImportc, sfExportc} * t.sym.flags != {}:
|
||||
c.hashSym(t.sym)
|
||||
of tyObject, tyEnum:
|
||||
if t.typeInst != nil and CoNoGeneric notin flags:
|
||||
if t.typeInst != nil:
|
||||
assert t.typeInst.kind == tyGenericInst
|
||||
for i in countup(1, sonsLen(t.typeInst) - 2):
|
||||
c.hashType t.typeInst.sons[i], flags+{CoNoGeneric}
|
||||
c.hashType t.typeInst.sons[i], flags
|
||||
# Every cyclic type in Nim need to be constructed via some 't.sym', so this
|
||||
# is actually safe without an infinite recursion check:
|
||||
if t.sym != nil:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue