first implementation of package level types that allow forwarding across module boundaries

This commit is contained in:
Andreas Rumpf 2017-10-28 15:28:59 +02:00
commit 7889692523
7 changed files with 47 additions and 21 deletions

View file

@ -1668,5 +1668,5 @@ template hasDestructor*(t: PType): bool = tfHasAsgn in t.flags
template incompleteType*(t: PType): bool =
t.sym != nil and {sfForward, sfNoForward} * t.sym.flags == {sfForward}
template typeCompleted*(t: PType) =
incl t.sym.flags, sfNoForward
template typeCompleted*(s: PSym) =
incl s.flags, sfNoForward