better overloading capabilities for 'shallowCopy'; little bugfix for 'system.compiles'

This commit is contained in:
Araq 2012-07-29 10:30:35 +02:00
commit 8c62903429
2 changed files with 15 additions and 12 deletions

View file

@ -45,6 +45,7 @@ proc semOrd(c: PContext, n: PNode): PNode =
result.typ = makeRangeType(c, firstOrd(n.sons[1].typ),
lastOrd(n.sons[1].typ), n.info)
proc semShallowCopy(c: PContext, n: PNode, flags: TExprFlags): PNode
proc magicsAfterOverloadResolution(c: PContext, n: PNode,
flags: TExprFlags): PNode =
case n[0].sym.magic
@ -55,5 +56,6 @@ proc magicsAfterOverloadResolution(c: PContext, n: PNode,
result.typ = getSysType(tyString)
of mInstantiationInfo: result = semInstantiationInfo(c, n)
of mOrd: result = semOrd(c, n)
of mShallowCopy: result = semShallowCopy(c, n, flags)
else: result = n