borrow checking (#15282)
* refactoring: move procs to typeallowed.nim * frontend preparations for first class openArray support * prepare the code generator for first class openArray * code generation for first class openArray; WIP * code generation for open arrays, progress * added isViewType proc * preparations for borrow checking * added borrow checking to the front end
This commit is contained in:
parent
c49b88163c
commit
10988d4840
18 changed files with 554 additions and 311 deletions
|
|
@ -534,7 +534,7 @@ proc semVarOrLet(c: PContext, n: PNode, symkind: TSymKind): PNode =
|
|||
|
||||
if c.matchedConcept != nil:
|
||||
typFlags.incl taConcept
|
||||
typeAllowedCheck(c.config, a.info, typ, symkind, typFlags)
|
||||
typeAllowedCheck(c, a.info, typ, symkind, typFlags)
|
||||
|
||||
when false: liftTypeBoundOps(c, typ, a.info)
|
||||
instAllTypeBoundOp(c, a.info)
|
||||
|
|
@ -667,7 +667,7 @@ proc semConst(c: PContext, n: PNode): PNode =
|
|||
if def.kind != nkNilLit:
|
||||
if c.matchedConcept != nil:
|
||||
typFlags.incl taConcept
|
||||
typeAllowedCheck(c.config, a.info, typ, skConst, typFlags)
|
||||
typeAllowedCheck(c, a.info, typ, skConst, typFlags)
|
||||
|
||||
var b: PNode
|
||||
if a.kind == nkVarTuple:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue