interpret tuple as a class and tuple[] as the empty tuple
When the indentation syntax is allowed it is always interpreted as a tuple: type Unit = tuple
This commit is contained in:
parent
bab8190b67
commit
9c126282b2
8 changed files with 16 additions and 11 deletions
|
|
@ -2055,7 +2055,7 @@ proc semExpr(c: PContext, n: PNode, flags: TExprFlags = {}): PNode =
|
|||
of nkBind:
|
||||
message(n.info, warnDeprecated, "bind")
|
||||
result = semExpr(c, n.sons[0], flags)
|
||||
of nkTypeOfExpr, nkTupleTy, nkRefTy..nkEnumTy, nkStaticTy:
|
||||
of nkTypeOfExpr, nkTupleTy, nkTupleClassTy, nkRefTy..nkEnumTy, nkStaticTy:
|
||||
var typ = semTypeNode(c, n, nil).skipTypes({tyTypeDesc, tyIter})
|
||||
result.typ = makeTypeDesc(c, typ)
|
||||
#result = symNodeFromType(c, typ, n.info)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue