bugfix: init of temps

This commit is contained in:
Araq 2010-08-24 00:19:16 +02:00
commit e439c6b02e
15 changed files with 107 additions and 76 deletions

View file

@ -663,10 +663,14 @@ proc semProcAux(c: PContext, n: PNode, kind: TSymKind,
n.sons[genericParamsPos] = semGenericParamList(c, n.sons[genericParamsPos])
gp = n.sons[genericParamsPos]
else:
gp = newNodeI(nkGenericParams, n.info) # process parameters:
gp = newNodeI(nkGenericParams, n.info)
# process parameters:
if n.sons[paramsPos] != nil:
semParamList(c, n.sons[ParamsPos], gp, s)
if sonsLen(gp) > 0: n.sons[genericParamsPos] = gp
if sonsLen(gp) > 0:
if n.sons[genericParamsPos] == nil:
# we have a list of implicit type parameters:
n.sons[genericParamsPos] = gp
addParams(c, s.typ.n)
else:
s.typ = newTypeS(tyProc, c)