bugfix: semantic checking: tuples without named fields
This commit is contained in:
parent
ce672c19d2
commit
8f41312ca6
2 changed files with 6 additions and 1 deletions
|
|
@ -662,7 +662,7 @@ proc builtinFieldAccess(c: PContext, n: PNode, flags: TExprFlags): PNode =
|
|||
check.sons[0] = n
|
||||
check.typ = n.typ
|
||||
result = check
|
||||
elif ty.kind == tyTuple:
|
||||
elif ty.kind == tyTuple and ty.n != nil:
|
||||
f = getSymFromList(ty.n, i)
|
||||
if f != nil:
|
||||
n.sons[0] = makeDeref(n.sons[0])
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue