Allow tyOr,tyAnd and tyNot to be constructed in more contexts
This commit is contained in:
parent
3e52bb6535
commit
bc01835091
3 changed files with 53 additions and 18 deletions
|
|
@ -277,6 +277,10 @@ proc makeTypeFromExpr*(c: PContext, n: PNode): PType =
|
|||
assert n != nil
|
||||
result.n = n
|
||||
|
||||
proc newTypeWithSons2*(kind: TTypeKind, owner: PSym, sons: seq[PType]): PType =
|
||||
result = newType(kind, owner)
|
||||
result.sons = sons
|
||||
|
||||
proc newTypeWithSons*(c: PContext, kind: TTypeKind,
|
||||
sons: seq[PType]): PType =
|
||||
result = newType(kind, getCurrOwner(c))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue