added 'reset' magic proc

This commit is contained in:
Araq 2011-03-25 01:49:42 +01:00
commit bd4f0b94ae
9 changed files with 73 additions and 12 deletions

View file

@ -392,7 +392,7 @@ proc analyseIfAddressTakenInCall(c: PContext, n: PNode) =
const
FakeVarParams = {mNew, mNewFinalize, mInc, ast.mDec, mIncl, mExcl,
mSetLengthStr, mSetLengthSeq, mAppendStrCh, mAppendStrStr, mSwap,
mAppendSeqElem, mNewSeq}
mAppendSeqElem, mNewSeq, mReset}
checkMinSonsLen(n, 1)
var t = n.sons[0].typ
if (n.sons[0].kind == nkSym) and (n.sons[0].sym.magic in FakeVarParams):