fixes for the new overloading resolution

This commit is contained in:
Araq 2013-03-03 16:35:19 +01:00
commit 4b0cdc6db7
4 changed files with 14 additions and 21 deletions

View file

@ -1526,8 +1526,9 @@ proc genMagicExpr(p: BProc, e: PNode, d: var TLoc, op: TMagic) =
of mNewFinalize: genNewFinalize(p, e)
of mNewSeq: genNewSeq(p, e)
of mSizeOf:
let t = e.sons[1].typ.skipTypes({tyTypeDesc})
putIntoDest(p, d, e.typ, ropef("((NI)sizeof($1))",
[getTypeDesc(p.module, e.sons[1].typ)]))
[getTypeDesc(p.module, t)]))
of mChr: genCast(p, e, d)
of mOrd: genOrd(p, e, d)
of mLengthArray, mHigh, mLengthStr, mLengthSeq, mLengthOpenArray: