This commit is contained in:
parent
5b195ab0f0
commit
04c48e3c5b
2 changed files with 17 additions and 0 deletions
|
|
@ -457,6 +457,7 @@ proc foldArrayAccess(m: PSym, n: PNode; idgen: IdGenerator; g: ModuleGraph): PNo
|
|||
|
||||
proc foldFieldAccess(m: PSym, n: PNode; idgen: IdGenerator; g: ModuleGraph): PNode =
|
||||
# a real field access; proc calls have already been transformed
|
||||
if n[1].kind != nkSym: return nil
|
||||
var x = getConstExpr(m, n[0], idgen, g)
|
||||
if x == nil or x.kind notin {nkObjConstr, nkPar, nkTupleConstr}: return
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue