better better fix for Issue #629 Recursive generic types not working
This commit is contained in:
parent
4330c986db
commit
f8206cb357
1 changed files with 4 additions and 5 deletions
|
|
@ -838,10 +838,9 @@ proc SameTypeAux(x, y: PType, c: var TSameTypeClosure): bool =
|
|||
of tyDistinct:
|
||||
CycleCheck()
|
||||
if c.cmp == dcEq:
|
||||
result = false
|
||||
if a.sym != nil and b.sym != nil:
|
||||
if a.sym.name == b.sym.name:
|
||||
result = sameTypeAux(a.sons[0], b.sons[0], c) and sameFlags(a, b)
|
||||
if sameFlags(a, b):
|
||||
IfFastObjectTypeCheckFailed(a, b):
|
||||
result = sameTypeAux(a.sons[0], b.sons[0], c)
|
||||
else:
|
||||
result = sameTypeAux(a.sons[0], b.sons[0], c) and sameFlags(a, b)
|
||||
of tyEnum, tyForward, tyProxy:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue