first version of 'spawn'

This commit is contained in:
Araq 2014-04-16 08:44:57 +02:00
commit 8e08ff559f
9 changed files with 188 additions and 37 deletions

View file

@ -30,6 +30,8 @@ proc semOperand(c: PContext, n: PNode, flags: TExprFlags = {}): PNode =
if result.typ != nil:
# XXX tyGenericInst here?
if result.typ.kind == tyVar: result = newDeref(result)
elif efWantStmt in flags:
result.typ = newTypeS(tyEmpty, c)
else:
localError(n.info, errExprXHasNoType,
renderTree(result, {renderNoComments}))